diff --git a/1. View/ContentView.swift b/1. View/ContentView.swift deleted file mode 100644 index 38cd9d6..0000000 --- a/1. View/ContentView.swift +++ /dev/null @@ -1,63 +0,0 @@ -// -// ContentView.swift -// AcaMate -// -// Created by Sean Kim on 11/26/24. -// - -import SwiftUI -import Combine - -private var cancellables = Set() - -struct ContentView: View { - - - var body: some View { - VStack { - Image(systemName: "globe") - .imageScale(.large) - .foregroundStyle(.tint) - Text("Hello, world!") - .background(Color("Point/Dark")) - Button { - SNSLogin().login(type: .Kakao) - -// self.versionCheck() - - } label : { - Text("카카오") - } - - } - .padding() - } - - func versionCheck() { - loadAPIData(url: "https://devacamate.ipstein.myds.me", - path: "/api/v1/in/app/version", - method: .get, - parameters: [ "type": "I"], - decodingType: APIResponse.self) - .sink { completion in - switch completion { - case .failure(let error): - printLog("ERROR: \(error)") - case .finished: - printLog("Version call Successed") - } - } receiveValue: { data in - guard let responseData = data as? APIResponse else {return} - printLog(responseData.status.toStringDict()) - printLog(responseData.data.toStringDict()) - } - .store(in: &cancellables) - } -} - - - - -#Preview { - ContentView() -} diff --git a/1. View/Intro&Login/IntroView.swift b/1. View/Intro&Login/IntroView.swift deleted file mode 100644 index 9e6ff64..0000000 --- a/1. View/Intro&Login/IntroView.swift +++ /dev/null @@ -1,43 +0,0 @@ -// -// IntroView.swift -// AcaMate -// -// Created by Sean Kim on 12/1/24. -// - -import SwiftUI -import Combine - -struct IntroView: View { - var body: some View { - VStack(spacing: 0) { - Spacer() - .frame(height: 100) - Image("Team_Icon") - .resizable() - .frame(width: 200, height: 200) - .background(.white) - .border(.black) - .padding() - Spacer() - HStack(spacing: 4) { - Image("Team_Icon") - .resizable() - .frame(width: 24, height: 24) - Text("STEIN") - .font(.nps(font: .bold, size: 16)) - .foregroundStyle(Color(.Text.detail)) - } - .padding(.bottom,12) - Text("Copyright © Team.Stein") - .font(.nps(font: .regular, size: 14)) - .foregroundStyle(Color(.Text.detail)) - .padding(.bottom,50) - } - .fullView(.Normal.normal) - } -} - -#Preview { - IntroView() -} diff --git a/1. View/Intro&Login/LoginView.swift b/1. View/Intro&Login/LoginView.swift deleted file mode 100644 index a3a119e..0000000 --- a/1. View/Intro&Login/LoginView.swift +++ /dev/null @@ -1,45 +0,0 @@ -// -// LoginView.swift -// AcaMate -// -// Created by Sean Kim on 12/1/24. -// - -import SwiftUI - -struct LoginView: View { - var body: some View { - VStack(spacing: 0) { - Image("Team_Icon") - .resizable() - .frame(width: 200, height: 200) - .background(.white) - .border(.black) - .padding(.bottom, 84) - Button { - - } label: { - HStack(spacing: 12) { - Image("Kakao_Icon") - .resizable() - .frame(width: 32, height: 32) - Text("카카오 계정으로 시작하기") - .font(.nps(font: .regular, size: 16)) - .foregroundStyle(Color(.Text.black)) - } - .padding(12) - .background { - RoundedRectangle(cornerRadius: 12) - .foregroundStyle(Color(.Other.yellow)) - } - } - - - } - .fullView(.Normal.normal) - } -} - -#Preview { - LoginView() -} diff --git a/AcaMate.xcodeproj/project.pbxproj b/AcaMate.xcodeproj/project.pbxproj index ce2430f..66ecf0f 100644 --- a/AcaMate.xcodeproj/project.pbxproj +++ b/AcaMate.xcodeproj/project.pbxproj @@ -7,6 +7,8 @@ objects = { /* Begin PBXBuildFile section */ + A771FFF22CFB70D100367DA6 /* KakaoSDK in Frameworks */ = {isa = PBXBuildFile; productRef = A771FFF12CFB70D100367DA6 /* KakaoSDK */; }; + A78774722CF586AF002FE2EE /* Alamofire in Frameworks */ = {isa = PBXBuildFile; productRef = A78774712CF586AF002FE2EE /* Alamofire */; }; A7A518CF2CF555E200822D0D /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = A7A518CE2CF555E200822D0D /* README.md */; }; A7A518D12CF5588500822D0D /* .gitignore in Resources */ = {isa = PBXBuildFile; fileRef = A7A518D02CF5588500822D0D /* .gitignore */; }; /* End PBXBuildFile section */ @@ -17,9 +19,22 @@ A7A518D02CF5588500822D0D /* .gitignore */ = {isa = PBXFileReference; lastKnownFileType = text; path = .gitignore; sourceTree = ""; }; /* End PBXFileReference section */ +/* Begin PBXFileSystemSynchronizedBuildFileExceptionSet section */ + A7FE24F82CFD2F4F00A147F8 /* Exceptions for "AcaMate" folder in "AcaMate" target */ = { + isa = PBXFileSystemSynchronizedBuildFileExceptionSet; + membershipExceptions = ( + Info.plist, + ); + target = A7A518BA2CF5558B00822D0D /* AcaMate */; + }; +/* End PBXFileSystemSynchronizedBuildFileExceptionSet section */ + /* Begin PBXFileSystemSynchronizedRootGroup section */ - A7A518BD2CF5558B00822D0D /* AcaMate */ = { + A7FE24DF2CFD2F4E00A147F8 /* AcaMate */ = { isa = PBXFileSystemSynchronizedRootGroup; + exceptions = ( + A7FE24F82CFD2F4F00A147F8 /* Exceptions for "AcaMate" folder in "AcaMate" target */, + ); path = AcaMate; sourceTree = ""; }; @@ -30,6 +45,8 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + A78774722CF586AF002FE2EE /* Alamofire in Frameworks */, + A771FFF22CFB70D100367DA6 /* KakaoSDK in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -41,7 +58,7 @@ children = ( A7A518D02CF5588500822D0D /* .gitignore */, A7A518CE2CF555E200822D0D /* README.md */, - A7A518BD2CF5558B00822D0D /* AcaMate */, + A7FE24DF2CFD2F4E00A147F8 /* AcaMate */, A7A518BC2CF5558B00822D0D /* Products */, ); sourceTree = ""; @@ -70,10 +87,12 @@ dependencies = ( ); fileSystemSynchronizedGroups = ( - A7A518BD2CF5558B00822D0D /* AcaMate */, + A7FE24DF2CFD2F4E00A147F8 /* AcaMate */, ); name = AcaMate; packageProductDependencies = ( + A78774712CF586AF002FE2EE /* Alamofire */, + A771FFF12CFB70D100367DA6 /* KakaoSDK */, ); productName = AcaMate; productReference = A7A518BB2CF5558B00822D0D /* AcaMate.app */; @@ -103,6 +122,10 @@ ); mainGroup = A7A518B22CF5558B00822D0D; minimizedProjectReferenceProxies = 1; + packageReferences = ( + A78774702CF586AF002FE2EE /* XCRemoteSwiftPackageReference "Alamofire" */, + A771FFF02CFB70D100367DA6 /* XCRemoteSwiftPackageReference "kakao-ios-sdk" */, + ); preferredProjectObjectVersion = 77; productRefGroup = A7A518BC2CF5558B00822D0D /* Products */; projectDirPath = ""; @@ -188,7 +211,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 18.1; + IPHONEOS_DEPLOYMENT_TARGET = 17.6; LOCALIZATION_PREFERS_STRING_CATALOGS = YES; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; @@ -196,6 +219,7 @@ SDKROOT = iphoneos; SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + VALIDATE_PRODUCT = YES; }; name = Debug; }; @@ -245,7 +269,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 18.1; + IPHONEOS_DEPLOYMENT_TARGET = 17.6; LOCALIZATION_PREFERS_STRING_CATALOGS = YES; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; @@ -260,27 +284,36 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = AcaMate/AcaMate.entitlements; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 1.0.0.0; DEVELOPMENT_ASSET_PATHS = "\"AcaMate/Preview Content\""; DEVELOPMENT_TEAM = 45MYH7ZHUQ; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = AcaMate/Info.plist; + INFOPLIST_KEY_NSUserTrackingUsageDescription = "최적화된 개인 간 연결과 맞춤 헤택을 위해 사용합니다."; INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.0; + MARKETING_VERSION = 1.0.0; PRODUCT_BUNDLE_IDENTIFIER = me.myds.ipstein.acamate.AcaMate; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited) DEV"; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = 1; }; name = Debug; }; @@ -289,27 +322,35 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_ENTITLEMENTS = AcaMate/AcaMate.entitlements; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 1.0.0.0; DEVELOPMENT_ASSET_PATHS = "\"AcaMate/Preview Content\""; DEVELOPMENT_TEAM = 45MYH7ZHUQ; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = AcaMate/Info.plist; + INFOPLIST_KEY_NSUserTrackingUsageDescription = "최적화된 개인 간 연결과 맞춤 헤택을 위해 사용합니다."; INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.0; + MARKETING_VERSION = 1.0.0; PRODUCT_BUNDLE_IDENTIFIER = me.myds.ipstein.acamate.AcaMate; PRODUCT_NAME = "$(TARGET_NAME)"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = 1; }; name = Release; }; @@ -335,6 +376,38 @@ defaultConfigurationName = Release; }; /* End XCConfigurationList section */ + +/* Begin XCRemoteSwiftPackageReference section */ + A771FFF02CFB70D100367DA6 /* XCRemoteSwiftPackageReference "kakao-ios-sdk" */ = { + isa = XCRemoteSwiftPackageReference; + repositoryURL = "https://github.com/kakao/kakao-ios-sdk"; + requirement = { + branch = master; + kind = branch; + }; + }; + A78774702CF586AF002FE2EE /* XCRemoteSwiftPackageReference "Alamofire" */ = { + isa = XCRemoteSwiftPackageReference; + repositoryURL = "https://github.com/Alamofire/Alamofire.git"; + requirement = { + kind = upToNextMajorVersion; + minimumVersion = 5.10.2; + }; + }; +/* End XCRemoteSwiftPackageReference section */ + +/* Begin XCSwiftPackageProductDependency section */ + A771FFF12CFB70D100367DA6 /* KakaoSDK */ = { + isa = XCSwiftPackageProductDependency; + package = A771FFF02CFB70D100367DA6 /* XCRemoteSwiftPackageReference "kakao-ios-sdk" */; + productName = KakaoSDK; + }; + A78774712CF586AF002FE2EE /* Alamofire */ = { + isa = XCSwiftPackageProductDependency; + package = A78774702CF586AF002FE2EE /* XCRemoteSwiftPackageReference "Alamofire" */; + productName = Alamofire; + }; +/* End XCSwiftPackageProductDependency section */ }; rootObject = A7A518B32CF5558B00822D0D /* Project object */; } diff --git a/AcaMate.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/AcaMate.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved new file mode 100644 index 0000000..cc84473 --- /dev/null +++ b/AcaMate.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -0,0 +1,24 @@ +{ + "originHash" : "48d44fe9560aaa48bc97ae34cdb596f62fa2d739be3dafd4261b95db8f8c86ab", + "pins" : [ + { + "identity" : "alamofire", + "kind" : "remoteSourceControl", + "location" : "https://github.com/Alamofire/Alamofire.git", + "state" : { + "revision" : "513364f870f6bfc468f9d2ff0a95caccc10044c5", + "version" : "5.10.2" + } + }, + { + "identity" : "kakao-ios-sdk", + "kind" : "remoteSourceControl", + "location" : "https://github.com/kakao/kakao-ios-sdk", + "state" : { + "branch" : "master", + "revision" : "ab4309c1950550add307046ad1e08024c7514603" + } + } + ], + "version" : 3 +} diff --git a/AcaMate.xcodeproj/project.xcworkspace/xcuserdata/seankim.xcuserdatad/UserInterfaceState.xcuserstate b/AcaMate.xcodeproj/project.xcworkspace/xcuserdata/seankim.xcuserdatad/UserInterfaceState.xcuserstate index 964d2f5..bb10369 100644 Binary files a/AcaMate.xcodeproj/project.xcworkspace/xcuserdata/seankim.xcuserdatad/UserInterfaceState.xcuserstate and b/AcaMate.xcodeproj/project.xcworkspace/xcuserdata/seankim.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/AcaMate.xcodeproj/xcshareddata/xcschemes/AcaMate.xcscheme b/AcaMate.xcodeproj/xcshareddata/xcschemes/AcaMate.xcscheme new file mode 100644 index 0000000..9662ddd --- /dev/null +++ b/AcaMate.xcodeproj/xcshareddata/xcschemes/AcaMate.xcscheme @@ -0,0 +1,78 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 0000000..f922ba0 --- /dev/null +++ b/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,6 @@ + + + diff --git a/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcschemes/xcschememanagement.plist b/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcschemes/xcschememanagement.plist index 1d122c1..07ecc11 100644 --- a/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcschemes/xcschememanagement.plist +++ b/AcaMate.xcodeproj/xcuserdata/seankim.xcuserdatad/xcschemes/xcschememanagement.plist @@ -10,5 +10,13 @@ 0 + SuppressBuildableAutocreation + + A7A518BA2CF5558B00822D0D + + primary + + + diff --git a/AcaMate/1. View/1. Intro & Login/IntroView.swift b/AcaMate/1. View/1. Intro & Login/IntroView.swift new file mode 100644 index 0000000..47ad830 --- /dev/null +++ b/AcaMate/1. View/1. Intro & Login/IntroView.swift @@ -0,0 +1,115 @@ +// +// IntroView.swift +// AcaMate +// +// Created by Sean Kim on 12/1/24. +// + +import SwiftUI +import Combine + +struct IntroView: View { + @State var cancellables: Set = [] + + var body: some View { + NavigationStack { + VStack(spacing: 0) { + Spacer() + .frame(height: 100) + Image("Team_Icon") + .resizable() + .frame(width: 200, height: 200) + .background(.white) + .border(.black) + .padding() + Spacer() + HStack(spacing: 4) { + Image("Team_Icon") + .resizable() + .frame(width: 24, height: 24) + Text("STEIN") + .font(.nps(font: .bold, size: 16)) + .foregroundStyle(Color(.Text.detail)) + } + .padding(.bottom,12) + Text("Copyright © Team.Stein") + .font(.nps(font: .regular, size: 14)) + .foregroundStyle(Color(.Text.detail)) + .padding(.bottom,50) + } + .fullView(.Normal.normal) + .onAppear { + printLog("IntroView_onAppear") + loadVersion() + .sink { completion in + switch completion { + case .failure(let error): + printLog(error) + case .finished: break + } + } receiveValue: { version in + switch compareVersion(version.force_ver, currentVersion()){ + case .bigger: + printLog("강제 업데이트") + default: + switch compareVersion(version.final_ver, currentVersion()) { + case .bigger: + if version.choice_update_yn { + printLog("선택 업데이트") + } + else { + printLog("정상 동작") + } + default: + printLog("선택 업데이트 넘어감") + } + } + } + .store(in: &cancellables) + + + } + } + } + + + private func loadVersion() -> Future { + return Future { promise in + loadAPIData(url: "\(API_URL)", + path: "/api/v1/in/app/version", + parameters: ["type":"I"], + decodingType: APIResponse.self) + .sink { completion in + switch completion { + case .failure(let error): + printLog("\(error)") + promise(.failure(error)) + case .finished: break + } + } receiveValue: { data in + guard let apiData = data as? APIResponse else {return} + printLog("\(apiData.data.toStringDict())") + promise(.success(apiData.data)) + } + .store(in: &cancellables) + } + + } + + private func currentVersion() -> String { + guard let currentVer = Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String else { return "" } + return currentVer + + } + + private func versionChange(ver: String) -> [Int] { + return ver.components(separatedBy: ["."]).map {Int($0) ?? 0} + } + + + +} + +#Preview { + IntroView() +} diff --git a/AcaMate/1. View/IntroView.swift b/AcaMate/1. View/IntroView.swift deleted file mode 100644 index 9e6ff64..0000000 --- a/AcaMate/1. View/IntroView.swift +++ /dev/null @@ -1,43 +0,0 @@ -// -// IntroView.swift -// AcaMate -// -// Created by Sean Kim on 12/1/24. -// - -import SwiftUI -import Combine - -struct IntroView: View { - var body: some View { - VStack(spacing: 0) { - Spacer() - .frame(height: 100) - Image("Team_Icon") - .resizable() - .frame(width: 200, height: 200) - .background(.white) - .border(.black) - .padding() - Spacer() - HStack(spacing: 4) { - Image("Team_Icon") - .resizable() - .frame(width: 24, height: 24) - Text("STEIN") - .font(.nps(font: .bold, size: 16)) - .foregroundStyle(Color(.Text.detail)) - } - .padding(.bottom,12) - Text("Copyright © Team.Stein") - .font(.nps(font: .regular, size: 14)) - .foregroundStyle(Color(.Text.detail)) - .padding(.bottom,50) - } - .fullView(.Normal.normal) - } -} - -#Preview { - IntroView() -} diff --git a/AcaMate/1. 이건?/ContentView.swift b/AcaMate/1. 이건?/ContentView.swift deleted file mode 100644 index 38cd9d6..0000000 --- a/AcaMate/1. 이건?/ContentView.swift +++ /dev/null @@ -1,63 +0,0 @@ -// -// ContentView.swift -// AcaMate -// -// Created by Sean Kim on 11/26/24. -// - -import SwiftUI -import Combine - -private var cancellables = Set() - -struct ContentView: View { - - - var body: some View { - VStack { - Image(systemName: "globe") - .imageScale(.large) - .foregroundStyle(.tint) - Text("Hello, world!") - .background(Color("Point/Dark")) - Button { - SNSLogin().login(type: .Kakao) - -// self.versionCheck() - - } label : { - Text("카카오") - } - - } - .padding() - } - - func versionCheck() { - loadAPIData(url: "https://devacamate.ipstein.myds.me", - path: "/api/v1/in/app/version", - method: .get, - parameters: [ "type": "I"], - decodingType: APIResponse.self) - .sink { completion in - switch completion { - case .failure(let error): - printLog("ERROR: \(error)") - case .finished: - printLog("Version call Successed") - } - } receiveValue: { data in - guard let responseData = data as? APIResponse else {return} - printLog(responseData.status.toStringDict()) - printLog(responseData.data.toStringDict()) - } - .store(in: &cancellables) - } -} - - - - -#Preview { - ContentView() -} diff --git a/AcaMate/1. 이건?/IntroView.swift b/AcaMate/1. 이건?/IntroView.swift deleted file mode 100644 index 9e6ff64..0000000 --- a/AcaMate/1. 이건?/IntroView.swift +++ /dev/null @@ -1,43 +0,0 @@ -// -// IntroView.swift -// AcaMate -// -// Created by Sean Kim on 12/1/24. -// - -import SwiftUI -import Combine - -struct IntroView: View { - var body: some View { - VStack(spacing: 0) { - Spacer() - .frame(height: 100) - Image("Team_Icon") - .resizable() - .frame(width: 200, height: 200) - .background(.white) - .border(.black) - .padding() - Spacer() - HStack(spacing: 4) { - Image("Team_Icon") - .resizable() - .frame(width: 24, height: 24) - Text("STEIN") - .font(.nps(font: .bold, size: 16)) - .foregroundStyle(Color(.Text.detail)) - } - .padding(.bottom,12) - Text("Copyright © Team.Stein") - .font(.nps(font: .regular, size: 14)) - .foregroundStyle(Color(.Text.detail)) - .padding(.bottom,50) - } - .fullView(.Normal.normal) - } -} - -#Preview { - IntroView() -} diff --git a/AcaMate/1. 이건?/LoginView.swift b/AcaMate/1. 이건?/LoginView.swift deleted file mode 100644 index a3a119e..0000000 --- a/AcaMate/1. 이건?/LoginView.swift +++ /dev/null @@ -1,45 +0,0 @@ -// -// LoginView.swift -// AcaMate -// -// Created by Sean Kim on 12/1/24. -// - -import SwiftUI - -struct LoginView: View { - var body: some View { - VStack(spacing: 0) { - Image("Team_Icon") - .resizable() - .frame(width: 200, height: 200) - .background(.white) - .border(.black) - .padding(.bottom, 84) - Button { - - } label: { - HStack(spacing: 12) { - Image("Kakao_Icon") - .resizable() - .frame(width: 32, height: 32) - Text("카카오 계정으로 시작하기") - .font(.nps(font: .regular, size: 16)) - .foregroundStyle(Color(.Text.black)) - } - .padding(12) - .background { - RoundedRectangle(cornerRadius: 12) - .foregroundStyle(Color(.Other.yellow)) - } - } - - - } - .fullView(.Normal.normal) - } -} - -#Preview { - LoginView() -} diff --git a/AcaMate/2. Common/SwiftUI_Prefix.swift b/AcaMate/2. Common/SwiftUI_Prefix.swift index bdeb173..b84cff5 100644 --- a/AcaMate/2. Common/SwiftUI_Prefix.swift +++ b/AcaMate/2. Common/SwiftUI_Prefix.swift @@ -5,6 +5,13 @@ // Created by Sean Kim on 2/20/24. // import SwiftUI +// MARK: - ACAMATE +#if DEV +public let API_URL: String = "https://devacamate.ipstein.myds.me" +#else +public let API_URL: String = "https://acamate.ipstein.myds.me" +#endif + // MARK: - TYPEALIAS typealias VOID_TO_VOID = () -> () diff --git a/AcaMate/4. Model/API Response.swift b/AcaMate/4. Model/API Response.swift index fda6788..890d0bf 100644 --- a/AcaMate/4. Model/API Response.swift +++ b/AcaMate/4. Model/API Response.swift @@ -22,6 +22,8 @@ class Status: Codable { class VersionData: Codable { let os_type, final_ver, dev_ver, force_ver: String let choice_update_yn: Bool + } + diff --git a/AcaMate/4. Model/Alert.swift b/AcaMate/4. Model/Alert.swift index e482f67..6c69cc5 100644 --- a/AcaMate/4. Model/Alert.swift +++ b/AcaMate/4. Model/Alert.swift @@ -5,4 +5,22 @@ // Created by Sean Kim on 12/2/24. // -import Foundation +import SwiftUI + +struct AlertData { + var title: String + var body: String + var button: [ButtonType] + + init(title: String = "알림", body: String, button: [ButtonType] = [.init(name: "확인", role: .none, function: nil)]) { + self.title = title + self.body = body + self.button = button + } +} + +struct ButtonType { + var name: String + var role: ButtonRole? + var function: (()->())? +} diff --git a/AcaMate/AcaMateApp.swift b/AcaMate/AcaMateApp.swift index a23d6ac..5454b18 100644 --- a/AcaMate/AcaMateApp.swift +++ b/AcaMate/AcaMateApp.swift @@ -6,6 +6,7 @@ // import SwiftUI +import Combine import KakaoSDKCommon import KakaoSDKAuth @@ -13,7 +14,11 @@ import KakaoSDKAuth @main struct AcaMateApp: App { @UIApplicationDelegateAdaptor(AppDelegate.self) var appDelegate + var cancellables: Set = [] + init() { + printLog("APP INIT") + } var body: some Scene { WindowGroup { diff --git a/AcaMate/IntroView.swift b/AcaMate/IntroView.swift deleted file mode 100644 index db36824..0000000 --- a/AcaMate/IntroView.swift +++ /dev/null @@ -1,18 +0,0 @@ -// -// IntroView.swift -// AcaMate -// -// Created by Sean Kim on 12/2/24. -// - -import SwiftUI - -struct IntroView: View { - var body: some View { - Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/) - } -} - -#Preview { - IntroView() -} diff --git a/AcaMate/LoginView.swift b/AcaMate/LoginView.swift deleted file mode 100644 index 0cb3d4d..0000000 --- a/AcaMate/LoginView.swift +++ /dev/null @@ -1,18 +0,0 @@ -// -// LoginVIew.swift -// AcaMate -// -// Created by Sean Kim on 12/2/24. -// - -import SwiftUI - -struct LoginVIew: View { - var body: some View { - Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/) - } -} - -#Preview { - LoginVIew() -} diff --git a/README.md b/README.md index 65f0890..ac336bd 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,13 @@ # ACAMATE +## Apple 라이브러리 +1. Push Notifications +2. Sign in with Apple + + +## 외부 라이브러리 +1. Alamofire +2. kakao Login +3. naver Map +4. firebase