diff --git a/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.pbxproj b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.pbxproj new file mode 100644 index 0000000..e34d53a --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.pbxproj @@ -0,0 +1,535 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 77; + objects = { + +/* Begin PBXBuildFile section */ + 4B870E342EB3A41400F55AB6 /* SnapKit in Frameworks */ = {isa = PBXBuildFile; productRef = 4B870E332EB3A41400F55AB6 /* SnapKit */; }; + 4B870E372EB3A59500F55AB6 /* Then in Frameworks */ = {isa = PBXBuildFile; productRef = 4B870E362EB3A59500F55AB6 /* Then */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 4B4031592EC794BF00146D39 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4B870D242EB399E300F55AB6 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4B870D2B2EB399E300F55AB6; + remoteInfo = "spot-37th-assignment"; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 4B4031552EC794BF00146D39 /* spot-37th-assignmentTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "spot-37th-assignmentTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; + 4B870D2C2EB399E300F55AB6 /* spot-37th-assignment.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "spot-37th-assignment.app"; sourceTree = BUILT_PRODUCTS_DIR; }; +/* End PBXFileReference section */ + +/* Begin PBXFileSystemSynchronizedBuildFileExceptionSet section */ + 4B870D3E2EB399E500F55AB6 /* Exceptions for "spot-37th-assignment" folder in "spot-37th-assignment" target */ = { + isa = PBXFileSystemSynchronizedBuildFileExceptionSet; + membershipExceptions = ( + Info.plist, + ); + target = 4B870D2B2EB399E300F55AB6 /* spot-37th-assignment */; + }; +/* End PBXFileSystemSynchronizedBuildFileExceptionSet section */ + +/* Begin PBXFileSystemSynchronizedRootGroup section */ + 4B4031562EC794BF00146D39 /* spot-37th-assignmentTests */ = { + isa = PBXFileSystemSynchronizedRootGroup; + path = "spot-37th-assignmentTests"; + sourceTree = ""; + }; + 4B870D2E2EB399E300F55AB6 /* spot-37th-assignment */ = { + isa = PBXFileSystemSynchronizedRootGroup; + exceptions = ( + 4B870D3E2EB399E500F55AB6 /* Exceptions for "spot-37th-assignment" folder in "spot-37th-assignment" target */, + ); + path = "spot-37th-assignment"; + sourceTree = ""; + }; +/* End PBXFileSystemSynchronizedRootGroup section */ + +/* Begin PBXFrameworksBuildPhase section */ + 4B4031522EC794BF00146D39 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4B870D292EB399E300F55AB6 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4B870E342EB3A41400F55AB6 /* SnapKit in Frameworks */, + 4B870E372EB3A59500F55AB6 /* Then in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 4B870D232EB399E300F55AB6 = { + isa = PBXGroup; + children = ( + 4B870D2E2EB399E300F55AB6 /* spot-37th-assignment */, + 4B4031562EC794BF00146D39 /* spot-37th-assignmentTests */, + 4B870D2D2EB399E300F55AB6 /* Products */, + ); + sourceTree = ""; + }; + 4B870D2D2EB399E300F55AB6 /* Products */ = { + isa = PBXGroup; + children = ( + 4B870D2C2EB399E300F55AB6 /* spot-37th-assignment.app */, + 4B4031552EC794BF00146D39 /* spot-37th-assignmentTests.xctest */, + ); + name = Products; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 4B4031542EC794BF00146D39 /* spot-37th-assignmentTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4B40315B2EC794BF00146D39 /* Build configuration list for PBXNativeTarget "spot-37th-assignmentTests" */; + buildPhases = ( + 4B4031512EC794BF00146D39 /* Sources */, + 4B4031522EC794BF00146D39 /* Frameworks */, + 4B4031532EC794BF00146D39 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 4B40315A2EC794BF00146D39 /* PBXTargetDependency */, + ); + fileSystemSynchronizedGroups = ( + 4B4031562EC794BF00146D39 /* spot-37th-assignmentTests */, + ); + name = "spot-37th-assignmentTests"; + packageProductDependencies = ( + ); + productName = "spot-37th-assignmentTests"; + productReference = 4B4031552EC794BF00146D39 /* spot-37th-assignmentTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 4B870D2B2EB399E300F55AB6 /* spot-37th-assignment */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4B870D3F2EB399E500F55AB6 /* Build configuration list for PBXNativeTarget "spot-37th-assignment" */; + buildPhases = ( + 4B870D282EB399E300F55AB6 /* Sources */, + 4B870D292EB399E300F55AB6 /* Frameworks */, + 4B870D2A2EB399E300F55AB6 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + fileSystemSynchronizedGroups = ( + 4B870D2E2EB399E300F55AB6 /* spot-37th-assignment */, + ); + name = "spot-37th-assignment"; + packageProductDependencies = ( + 4B870E332EB3A41400F55AB6 /* SnapKit */, + 4B870E362EB3A59500F55AB6 /* Then */, + ); + productName = "spot-37th-assignment"; + productReference = 4B870D2C2EB399E300F55AB6 /* spot-37th-assignment.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 4B870D242EB399E300F55AB6 /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 2610; + LastUpgradeCheck = 2610; + TargetAttributes = { + 4B4031542EC794BF00146D39 = { + CreatedOnToolsVersion = 26.1.1; + TestTargetID = 4B870D2B2EB399E300F55AB6; + }; + 4B870D2B2EB399E300F55AB6 = { + CreatedOnToolsVersion = 26.0.1; + }; + }; + }; + buildConfigurationList = 4B870D272EB399E300F55AB6 /* Build configuration list for PBXProject "spot-37th-assignment" */; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 4B870D232EB399E300F55AB6; + minimizedProjectReferenceProxies = 1; + packageReferences = ( + 4B870E322EB3A41400F55AB6 /* XCRemoteSwiftPackageReference "SnapKit" */, + 4B870E352EB3A59500F55AB6 /* XCRemoteSwiftPackageReference "Then" */, + ); + preferredProjectObjectVersion = 77; + productRefGroup = 4B870D2D2EB399E300F55AB6 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 4B870D2B2EB399E300F55AB6 /* spot-37th-assignment */, + 4B4031542EC794BF00146D39 /* spot-37th-assignmentTests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 4B4031532EC794BF00146D39 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4B870D2A2EB399E300F55AB6 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 4B4031512EC794BF00146D39 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4B870D282EB399E300F55AB6 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 4B40315A2EC794BF00146D39 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4B870D2B2EB399E300F55AB6 /* spot-37th-assignment */; + targetProxy = 4B4031592EC794BF00146D39 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 4B40315C2EC794BF00146D39 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEAD_CODE_STRIPPING = YES; + DEVELOPMENT_TEAM = NZJWJ35U9D; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + MACOSX_DEPLOYMENT_TARGET = 26.0; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.jaesuneo.spot-37th-assignmentTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + STRING_CATALOG_GENERATE_SYMBOLS = NO; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator"; + SWIFT_APPROACHABLE_CONCURRENCY = YES; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2,7"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/spot-37th-assignment.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/spot-37th-assignment"; + XROS_DEPLOYMENT_TARGET = 26.0; + }; + name = Debug; + }; + 4B40315D2EC794BF00146D39 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEAD_CODE_STRIPPING = YES; + DEVELOPMENT_TEAM = NZJWJ35U9D; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + MACOSX_DEPLOYMENT_TARGET = 26.0; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.jaesuneo.spot-37th-assignmentTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = auto; + STRING_CATALOG_GENERATE_SYMBOLS = NO; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator"; + SWIFT_APPROACHABLE_CONCURRENCY = YES; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2,7"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/spot-37th-assignment.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/spot-37th-assignment"; + XROS_DEPLOYMENT_TARGET = 26.0; + }; + name = Release; + }; + 4B870D402EB399E500F55AB6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = NZJWJ35U9D; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = "spot-37th-assignment/Info.plist"; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.jaesuneo.spot-37th-assignment"; + PRODUCT_NAME = "$(TARGET_NAME)"; + STRING_CATALOG_GENERATE_SYMBOLS = YES; + SWIFT_APPROACHABLE_CONCURRENCY = YES; + SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 4B870D412EB399E500F55AB6 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_TEAM = NZJWJ35U9D; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_FILE = "spot-37th-assignment/Info.plist"; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.jaesuneo.spot-37th-assignment"; + PRODUCT_NAME = "$(TARGET_NAME)"; + STRING_CATALOG_GENERATE_SYMBOLS = YES; + SWIFT_APPROACHABLE_CONCURRENCY = YES; + SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 4B870D422EB399E500F55AB6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = NZJWJ35U9D; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + STRING_CATALOG_GENERATE_SYMBOLS = YES; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 4B870D432EB399E500F55AB6 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = NZJWJ35U9D; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu17; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 26.0; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + STRING_CATALOG_GENERATE_SYMBOLS = YES; + SWIFT_COMPILATION_MODE = wholemodule; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 4B40315B2EC794BF00146D39 /* Build configuration list for PBXNativeTarget "spot-37th-assignmentTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4B40315C2EC794BF00146D39 /* Debug */, + 4B40315D2EC794BF00146D39 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4B870D272EB399E300F55AB6 /* Build configuration list for PBXProject "spot-37th-assignment" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4B870D422EB399E500F55AB6 /* Debug */, + 4B870D432EB399E500F55AB6 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4B870D3F2EB399E500F55AB6 /* Build configuration list for PBXNativeTarget "spot-37th-assignment" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4B870D402EB399E500F55AB6 /* Debug */, + 4B870D412EB399E500F55AB6 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + +/* Begin XCRemoteSwiftPackageReference section */ + 4B870E322EB3A41400F55AB6 /* XCRemoteSwiftPackageReference "SnapKit" */ = { + isa = XCRemoteSwiftPackageReference; + repositoryURL = "https://github.com/SnapKit/SnapKit.git"; + requirement = { + kind = upToNextMajorVersion; + minimumVersion = 5.7.1; + }; + }; + 4B870E352EB3A59500F55AB6 /* XCRemoteSwiftPackageReference "Then" */ = { + isa = XCRemoteSwiftPackageReference; + repositoryURL = "https://github.com/devxoul/Then"; + requirement = { + kind = upToNextMajorVersion; + minimumVersion = 3.0.0; + }; + }; +/* End XCRemoteSwiftPackageReference section */ + +/* Begin XCSwiftPackageProductDependency section */ + 4B870E332EB3A41400F55AB6 /* SnapKit */ = { + isa = XCSwiftPackageProductDependency; + package = 4B870E322EB3A41400F55AB6 /* XCRemoteSwiftPackageReference "SnapKit" */; + productName = SnapKit; + }; + 4B870E362EB3A59500F55AB6 /* Then */ = { + isa = XCSwiftPackageProductDependency; + package = 4B870E352EB3A59500F55AB6 /* XCRemoteSwiftPackageReference "Then" */; + productName = Then; + }; +/* End XCSwiftPackageProductDependency section */ + }; + rootObject = 4B870D242EB399E300F55AB6 /* Project object */; +} diff --git a/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..919434a --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved new file mode 100644 index 0000000..da17c27 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -0,0 +1,24 @@ +{ + "originHash" : "dc78d9f78c6dffeef10c87cabc223dde5b29ad30f0c1897eba28f817c2359a8a", + "pins" : [ + { + "identity" : "snapkit", + "kind" : "remoteSourceControl", + "location" : "https://github.com/SnapKit/SnapKit.git", + "state" : { + "revision" : "2842e6e84e82eb9a8dac0100ca90d9444b0307f4", + "version" : "5.7.1" + } + }, + { + "identity" : "then", + "kind" : "remoteSourceControl", + "location" : "https://github.com/devxoul/Then", + "state" : { + "revision" : "d41ef523faef0f911369f79c0b96815d9dbb6d7a", + "version" : "3.0.0" + } + } + ], + "version" : 3 +} diff --git a/spot-37th-assignment/spot-37th-assignment/AppDelegate.swift b/spot-37th-assignment/spot-37th-assignment/AppDelegate.swift new file mode 100644 index 0000000..45bdd13 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/AppDelegate.swift @@ -0,0 +1,36 @@ +// +// AppDelegate.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import UIKit + +@main +class AppDelegate: UIResponder, UIApplicationDelegate { + + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + // MARK: UISceneSession Lifecycle + + func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration { + // Called when a new scene session is being created. + // Use this method to select a configuration to create the new scene with. + return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role) + } + + func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set) { + // Called when the user discards a scene session. + // If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions. + // Use this method to release any resources that were specific to the discarded scenes, as they will not return. + } + + +} + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AccentColor.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 0000000..eb87897 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AppIcon.appiconset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..2305880 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,35 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + }, + { + "appearances" : [ + { + "appearance" : "luminosity", + "value" : "dark" + } + ], + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + }, + { + "appearances" : [ + { + "appearance" : "luminosity", + "value" : "tinted" + } + ], + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_black.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_black.colorset/Contents.json new file mode 100644 index 0000000..52b167f --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_black.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0x1C", + "green" : "0x1A", + "red" : "0x18" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_200.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_200.colorset/Contents.json new file mode 100644 index 0000000..8f787d3 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_200.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0xD9", + "green" : "0xD3", + "red" : "0xD1" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_300.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_300.colorset/Contents.json new file mode 100644 index 0000000..a8988dd --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_300.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0xB5", + "green" : "0xB3", + "red" : "0xB1" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_700.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_700.colorset/Contents.json new file mode 100644 index 0000000..d8a3773 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_gray_700.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0x66", + "green" : "0x66", + "red" : "0x66" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_300.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_300.colorset/Contents.json new file mode 100644 index 0000000..eb857fa --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_300.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0xDB", + "green" : "0xE3", + "red" : "0x7F" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_500.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_500.colorset/Contents.json new file mode 100644 index 0000000..c7481a2 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_mint_500.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0xB3", + "green" : "0xB8", + "red" : "0x28" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_white.colorset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_white.colorset/Contents.json new file mode 100644 index 0000000..e72f1c2 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baemincolor/baemin_white.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "display-p3", + "components" : { + "alpha" : "1.000", + "blue" : "0xFF", + "green" : "0xFF", + "red" : "0xFF" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/Contents.json new file mode 100644 index 0000000..e54d867 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "baemin-ArrowLeft.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/baemin-ArrowLeft.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/baemin-ArrowLeft.svg new file mode 100644 index 0000000..d1b8402 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ArrowLeft.imageset/baemin-ArrowLeft.svg @@ -0,0 +1,3 @@ + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/Contents.json new file mode 100644 index 0000000..17bae48 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-ChevronRight.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/beamin-ChevronRight.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/beamin-ChevronRight.svg new file mode 100644 index 0000000..4d59870 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-ChevronRight.imageset/beamin-ChevronRight.svg @@ -0,0 +1,3 @@ + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/Contents.json new file mode 100644 index 0000000..b5febed --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-btn_before.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/beamin-btn_before.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/beamin-btn_before.svg new file mode 100644 index 0000000..f3d9d35 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-btn_before.imageset/beamin-btn_before.svg @@ -0,0 +1,3 @@ + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/Contents.json new file mode 100644 index 0000000..f886ecc --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-eye-slash.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/beamin-eye-slash.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/beamin-eye-slash.svg new file mode 100644 index 0000000..76e0742 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye-slash.imageset/beamin-eye-slash.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/Contents.json new file mode 100644 index 0000000..54f7364 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-eye.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/beamin-eye.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/beamin-eye.svg new file mode 100644 index 0000000..e9e7195 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-eye.imageset/beamin-eye.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/Contents.json new file mode 100644 index 0000000..3b6667d --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "baemin-x-circle-fill.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/baemin-x-circle-fill.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/baemin-x-circle-fill.svg new file mode 100644 index 0000000..de4898e --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle-fill.imageset/baemin-x-circle-fill.svg @@ -0,0 +1,4 @@ + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/Contents.json new file mode 100644 index 0000000..cf22c24 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-x-circle.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/beamin-x-circle.svg b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/beamin-x-circle.svg new file mode 100644 index 0000000..a416cb0 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminicon/baemin-x-circle.imageset/beamin-x-circle.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/Contents.json b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/Contents.json new file mode 100644 index 0000000..f9a9dec --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "beamin-image1.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/beamin-image1.png b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/beamin-image1.png new file mode 100644 index 0000000..a1870e3 Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Assets.xcassets/baeminimage/baemin-image1.imageset/beamin-image1.png differ diff --git a/spot-37th-assignment/spot-37th-assignment/Base.lproj/LaunchScreen.storyboard b/spot-37th-assignment/spot-37th-assignment/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 0000000..865e932 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/Extension/Font+Extension.swift b/spot-37th-assignment/spot-37th-assignment/Extension/Font+Extension.swift new file mode 100644 index 0000000..0eb6434 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Extension/Font+Extension.swift @@ -0,0 +1,31 @@ +// +// Font+Extension.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import Foundation +import UIKit + +enum PretendardWeight: String { + case black = "Pretendard-Black" + case bold = "Pretendard-Bold" + case extraBold = "Pretendard-ExtraBold" + case extraLight = "Pretendard-ExtraLight" + case light = "Pretendard-Light" + case medium = "Pretendard-Medium" + case regular = "Pretendard-Regular" + case semiBold = "Pretendard-SemiBold" + case thin = "Pretendard-Thin" +} + +extension UIFont { + + static let head_b_24: UIFont = UIFont(name: PretendardWeight.bold.rawValue, size: 24) ?? UIFont() + static let head_b_18: UIFont = UIFont(name: PretendardWeight.bold.rawValue, size: 18) ?? UIFont() + static let title_sb_18: UIFont = UIFont(name: PretendardWeight.semiBold.rawValue, size: 18) ?? UIFont() + static let body_r_14: UIFont = UIFont(name: PretendardWeight.regular.rawValue, size: 14) ?? UIFont() + static let caption_r_10: UIFont = UIFont(name: PretendardWeight.regular.rawValue, size: 10) ?? UIFont() + +} diff --git a/spot-37th-assignment/spot-37th-assignment/Extension/TextField+Extension.swift b/spot-37th-assignment/spot-37th-assignment/Extension/TextField+Extension.swift new file mode 100644 index 0000000..93ba41c --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Extension/TextField+Extension.swift @@ -0,0 +1,27 @@ +// +// TextField+Extension.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import UIKit + +extension UITextField { + func addLeftPadding(_ width: CGFloat = 10) { + let paddingView = UIView(frame: CGRect(x: 0, y: 0, width: width, height: self.frame.height)) + self.leftView = paddingView + self.leftViewMode = ViewMode.always + } + + func addRightPadding(_ width: CGFloat = 10) { + let paddingView = UIView(frame: CGRect(x: 0, y: 0, width: width, height: self.frame.height)) + self.rightView = paddingView + self.rightViewMode = ViewMode.always + } + + func setPlaceholder(color: UIColor) { + guard let string = self.placeholder else { return } + attributedPlaceholder = NSAttributedString(string: string, attributes: [.foregroundColor: color]) + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Extension/ViewController+Extension.swift b/spot-37th-assignment/spot-37th-assignment/Extension/ViewController+Extension.swift new file mode 100644 index 0000000..4af4a55 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Extension/ViewController+Extension.swift @@ -0,0 +1,20 @@ +// +// ViewController+Extension.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/31/25. +// + +import UIKit + +extension UIViewController { + func hideKeyboardWhenTappedAround() { + let tap = UITapGestureRecognizer(target: self, action: #selector(UIViewController.dismissKeyboard)) + tap.cancelsTouchesInView = false + view.addGestureRecognizer(tap) + } + + @objc func dismissKeyboard() { + view.endEditing(true) + } +} diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Black.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Black.otf new file mode 100644 index 0000000..a0d849e Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Black.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Bold.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Bold.otf new file mode 100644 index 0000000..8e5e30a Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Bold.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraBold.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraBold.otf new file mode 100644 index 0000000..388f3ca Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraBold.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraLight.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraLight.otf new file mode 100644 index 0000000..40c8b69 Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-ExtraLight.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Light.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Light.otf new file mode 100644 index 0000000..228679e Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Light.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Medium.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Medium.otf new file mode 100644 index 0000000..0575069 Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Medium.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Regular.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Regular.otf new file mode 100644 index 0000000..08bf4cf Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Regular.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-SemiBold.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-SemiBold.otf new file mode 100644 index 0000000..e7e36ab Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-SemiBold.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Thin.otf b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Thin.otf new file mode 100644 index 0000000..77e792d Binary files /dev/null and b/spot-37th-assignment/spot-37th-assignment/Fonts/Pretendard-Thin.otf differ diff --git a/spot-37th-assignment/spot-37th-assignment/Info.plist b/spot-37th-assignment/spot-37th-assignment/Info.plist new file mode 100644 index 0000000..b86d365 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/Info.plist @@ -0,0 +1,34 @@ + + + + + UIAppFonts + + Pretendard-Black.otf + Pretendard-Bold.otf + Pretendard-ExtraBold.otf + Pretendard-ExtraLight.otf + Pretendard-Medium.otf + Pretendard-Regular.otf + Pretendard-SemiBold.otf + Pretendard-Thin.otf + + UIApplicationSceneManifest + + UIApplicationSupportsMultipleScenes + + UISceneConfigurations + + UIWindowSceneSessionRoleApplication + + + UISceneConfigurationName + Default Configuration + UISceneDelegateClassName + $(PRODUCT_MODULE_NAME).SceneDelegate + + + + + + diff --git a/spot-37th-assignment/spot-37th-assignment/LoginViewController.swift b/spot-37th-assignment/spot-37th-assignment/LoginViewController.swift new file mode 100644 index 0000000..35d9fbc --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/LoginViewController.swift @@ -0,0 +1,244 @@ +// +// LoginViewController.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import UIKit +import Then +import SnapKit + +final class LoginViewController: UIViewController { + + private let emailTextField = UITextField() + private let passwordTextField = UITextField() + private lazy var loginButton = UIButton() + private lazy var selectAccountButton = UIButton() + private lazy var clearButton = UIButton() + private lazy var toggleButton = UIButton() + private let rightButtonView = UIStackView() + override func viewDidLoad() { + + super.viewDidLoad() + self.hideKeyboardWhenTappedAround() + setStyle() + setHierarchy() + setLayout() + + } +} + +extension LoginViewController { + func setStyle() { + self.view.backgroundColor = .white + self.navigationItem.title = "이메일 또는 아이디로 계속" + self.emailTextField.do { + $0.delegate = self + $0.placeholder = "이메일 아이디" + $0.font = .body_r_14 + $0.layer.cornerRadius = 4 + $0.layer.borderWidth = 1 + $0.layer.borderColor = UIColor.baeminGray200.cgColor + $0.addLeftPadding(10) + $0.setPlaceholder(color: .baeminGray700) + $0.tintColor = .baeminMint300 + $0.clearButtonMode = .whileEditing + } + + self.passwordTextField.do { + + $0.delegate = self + $0.placeholder = "비밀번호" + $0.font = .body_r_14 + $0.layer.cornerRadius = 4 + $0.layer.borderWidth = 1 + $0.layer.borderColor = UIColor.baeminGray200.cgColor + $0.addLeftPadding(10) + $0.setPlaceholder(color: .baeminGray700) + $0.isSecureTextEntry = true + $0.tintColor = .baeminMint300 + $0.rightView = rightButtonView + $0.rightViewMode = .whileEditing + } + + self.loginButton.do { + $0.setTitle("로그인", for: .normal) + $0.setTitleColor(.baeminWhite, for: .normal) + $0.backgroundColor = .baeminGray200 + $0.titleLabel?.font = .head_b_18 + $0.addTarget(self, action: #selector(loginButtonDidTap), for: .touchUpInside) + $0.layer.cornerRadius = 4 + $0.isEnabled = false + } + self.selectAccountButton.do { + $0.setTitle("계정 찾기", for: .normal) + $0.setTitleColor(.baeminBlack, for: .normal) + $0.setImage(UIImage(named: "baemin-ChevronRight"), for: .normal) + $0.titleLabel?.font = .body_r_14 + $0.semanticContentAttribute = .forceRightToLeft + } + + self.rightButtonView.do { + $0.axis = .horizontal + $0.spacing = 16 + $0.alignment = .center + $0.layoutMargins = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 10) + $0.isLayoutMarginsRelativeArrangement = true + + } + self.clearButton.do { + $0.setImage(UIImage(named: "baemin-x-circle-fill"), for: .normal) + $0.tintColor = .baeminGray300 + $0.frame = CGRect(x: 0, y: 0, width: 24, height: 24) + $0.isHidden = true + + } + + self.toggleButton.do { + $0.setImage(UIImage(named: "baemin-eye-slash"), for: .normal) + $0.frame = CGRect(x: 0, y: 0, width: 20, height: 20) + + } + + } + + func setHierarchy() { + + rightButtonView.addArrangedSubview(clearButton) + rightButtonView.addArrangedSubview(toggleButton) + + [emailTextField,passwordTextField,loginButton, selectAccountButton,selectAccountButton].forEach { + self.view.addSubview($0) + } + + } + + func setLayout() { + + + self.emailTextField.snp.makeConstraints { + $0.top.equalToSuperview().offset(101) + $0.leading.trailing.equalToSuperview().inset(16) + $0.width.equalTo(343) + $0.height.equalTo(46) + } + + self.passwordTextField.snp.makeConstraints { + $0.top.equalTo(self.emailTextField.snp.bottom).offset(12) + $0.leading.trailing.equalToSuperview().inset(16) + $0.width.equalTo(343) + $0.height.equalTo(46) + } + + self.loginButton.snp.makeConstraints { + $0.top.equalTo(passwordTextField.snp.bottom).offset(20) + $0.leading.trailing.equalToSuperview().inset(16) + $0.width.equalTo(343) + $0.height.equalTo(46) + } + self.selectAccountButton.snp.makeConstraints { + $0.top.equalTo(self.loginButton.snp.bottom).offset(32) + $0.leading.trailing.equalToSuperview().inset(16) + $0.width.equalTo(66) + $0.height.equalTo(14) + } + + + } + + @objc func loginButtonDidTap() { + guard let emailText = emailTextField.text else { return } + guard let passwordText = passwordTextField.text else { return } + + + + if isValidEmail(email: emailText) { + if !emailText.isEmpty && !passwordText.isEmpty { + let welcomeViewController = WelcomeViewController() + + guard let name = emailText.split(separator: "@").first else { return } + welcomeViewController.setLabelText(name: String(name)) + self.navigationController?.pushViewController(welcomeViewController, animated: true) + } + } else { + let alert = UIAlertController(title: "알림", message: "이메일 형식이 달라요", preferredStyle: .alert) + + let okAction = UIAlertAction(title: "확인", style: .default) + alert.addAction(okAction) + + present(alert, animated: true, completion: nil) + } + } + + func isValidEmail(email: String) -> Bool { + let emailRegex = "[A-Z0-9a-z._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}" + let emailPredicate = NSPredicate(format: "SELF MATCHES %@", emailRegex) + return emailPredicate.evaluate(with: email) + } + + + +} + +extension LoginViewController: UITextFieldDelegate { + func textFieldDidEndEditing(_ textField: UITextField) { + textField.layer.borderColor = UIColor.baeminGray200.cgColor + textField.layer.borderWidth = 1 + + guard let emailText = emailTextField.text else { return } + guard let passwordText = passwordTextField.text else { return } + + if !emailText.isEmpty && !passwordText.isEmpty { + loginButton.backgroundColor = .baeminMint500 + loginButton.isEnabled = true + } + } + + func textField(_ textField: UITextField, shouldChangeCharactersInRanges ranges: [NSValue], replacementString string: String) -> Bool { + + + if let passwordText = passwordTextField.text { + if passwordText.isEmpty { + clearButton.isHidden = true + } else { + clearButton.isHidden = false + } + } + return true + } + + + func textFieldDidBeginEditing(_ textField: UITextField) { + textField.layer.borderColor = UIColor.baeminBlack.cgColor + textField.layer.borderWidth = 2 + + if let passwordText = passwordTextField.text { + if passwordText.isEmpty { + clearButton.isHidden = true + } else { + clearButton.isHidden = false + } + } + + + + clearButton.addTarget(self, action: #selector(clearButtonAction), for: .touchUpInside) + toggleButton.addTarget(self, action: #selector(toggleButtonAction), for: .touchUpInside) + } + + @objc func clearButtonAction() { + passwordTextField.text = "" + passwordTextField.becomeFirstResponder() + } + + @objc func toggleButtonAction() { + passwordTextField.isSecureTextEntry.toggle() + toggleButton.setImage(UIImage(named: passwordTextField.isSecureTextEntry ? "baemin-eye-slash" : "baemin-eye"), for: .normal) + passwordTextField.becomeFirstResponder() + } +} + +#Preview { + LoginViewController() +} diff --git a/spot-37th-assignment/spot-37th-assignment/SceneDelegate.swift b/spot-37th-assignment/spot-37th-assignment/SceneDelegate.swift new file mode 100644 index 0000000..7efc307 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/SceneDelegate.swift @@ -0,0 +1,62 @@ +// +// SceneDelegate.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import UIKit + +class SceneDelegate: UIResponder, UIWindowSceneDelegate { + + var window: UIWindow? + + + func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { + // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`. + // If using a storyboard, the `window` property will automatically be initialized and attached to the scene. + // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). + guard let windowScene = (scene as? UIWindowScene) else { return } + let window = UIWindow(windowScene: windowScene) + + let viewController = UINavigationController(rootViewController: ViewController()) + + window.rootViewController = viewController + + self.window = window + + window.makeKeyAndVisible() + + } + + func sceneDidDisconnect(_ scene: UIScene) { + // Called as the scene is being released by the system. + // This occurs shortly after the scene enters the background, or when its session is discarded. + // Release any resources associated with this scene that can be re-created the next time the scene connects. + // The scene may re-connect later, as its session was not necessarily discarded (see `application:didDiscardSceneSessions` instead). + } + + func sceneDidBecomeActive(_ scene: UIScene) { + // Called when the scene has moved from an inactive state to an active state. + // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive. + } + + func sceneWillResignActive(_ scene: UIScene) { + // Called when the scene will move from an active state to an inactive state. + // This may occur due to temporary interruptions (ex. an incoming phone call). + } + + func sceneWillEnterForeground(_ scene: UIScene) { + // Called as the scene transitions from the background to the foreground. + // Use this method to undo the changes made on entering the background. + } + + func sceneDidEnterBackground(_ scene: UIScene) { + // Called as the scene transitions from the foreground to the background. + // Use this method to save data, release shared resources, and store enough scene-specific state information + // to restore the scene back to its current state. + } + + +} + diff --git a/spot-37th-assignment/spot-37th-assignment/ViewController.swift b/spot-37th-assignment/spot-37th-assignment/ViewController.swift new file mode 100644 index 0000000..6f004fa --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/ViewController.swift @@ -0,0 +1,59 @@ +// +// ViewController.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/30/25. +// + +import UIKit +import SnapKit +import Then + +final class ViewController: UIViewController { + + private lazy var loginButton = UIButton() + + override func viewDidLoad() { + super.viewDidLoad() + setHierarchy() + setStyle() + setLayout() + + } + +} + +extension ViewController { + + func setStyle() { + loginButton.do { + $0.setTitle("로그인하기", for: .normal) + $0.setTitleColor(.baeminWhite, for: .normal) + $0.backgroundColor = .baeminMint500 + $0.titleLabel?.font = .head_b_24 + $0.addTarget(self, action: #selector(loginButtonDidTap), for: .touchUpInside) + $0.layer.cornerRadius = 4 + } + } + func setHierarchy() { + self.view.addSubview(loginButton) + } + + func setLayout() { + self.view.backgroundColor = .baeminWhite + + self.loginButton.snp.makeConstraints { + $0.center.equalToSuperview() + $0.width.equalTo(343) + $0.height.equalTo(46) + + } + + } + + @objc func loginButtonDidTap() { + let loginViewController = LoginViewController() + self.navigationController?.pushViewController(loginViewController, animated: true) + } +} + diff --git a/spot-37th-assignment/spot-37th-assignment/WelcomeViewController.swift b/spot-37th-assignment/spot-37th-assignment/WelcomeViewController.swift new file mode 100644 index 0000000..f620a8b --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignment/WelcomeViewController.swift @@ -0,0 +1,116 @@ +// +// WelcomeViewController.swift +// spot-37th-assignment +// +// Created by 어재선 on 10/31/25. +// + +import UIKit +import SnapKit +import Then + + + +final class WelcomeViewController: UIViewController { + + private let imageView = UIImageView() + private let titleLabel = UILabel() + private let subTitleLabel = UILabel() + private let backButton = UIButton() + + private var name: String? + + override func viewDidLoad() { + super.viewDidLoad() + self.setStyle() + self.setHierarchy() + self.setlayout() + self.bindEmail() + } +} + +// MARK: - UI +extension WelcomeViewController { + func setStyle() { + self.view.backgroundColor = .baeminWhite + self.navigationItem.title = "대체 뼈짐 누가 시켰어" + + self.imageView.do { + $0.image = UIImage(named: "baemin-image1") + $0.sizeToFit() + } + + self.titleLabel.do { + $0.text = "환영합니다." + $0.font = .head_b_24 + $0.textColor = .baeminBlack + $0.textAlignment = .center + } + + self.subTitleLabel.do { + $0.text = "OO님 반가워요!" + $0.font = .head_b_18 + $0.textColor = .baeminBlack + $0.textAlignment = .center + + } + + self.backButton.do { + $0.setTitle("뒤로가기", for: .normal) + $0.setTitleColor(.baeminWhite, for: .normal) + $0.backgroundColor = .baeminMint500 + $0.titleLabel?.font = .head_b_18 + $0.addTarget(self, action: #selector(backButtonDidTap), for: .touchUpInside) + $0.layer.cornerRadius = 4 + } + + } + + func setHierarchy() { + [self.imageView, self.titleLabel, self.subTitleLabel,self.backButton].forEach { + self.view.addSubview($0) + } + } + + func setlayout() { + + self.imageView.snp.makeConstraints { + $0.top.equalToSuperview().offset(101) + $0.left.right.equalToSuperview() + $0.height.equalTo(211) + } + + self.titleLabel.snp.makeConstraints { + $0.top.equalTo(self.imageView.snp.bottom).offset(24) + $0.centerX.equalToSuperview() + } + + self.subTitleLabel.snp.makeConstraints { + $0.top.equalTo(self.titleLabel.snp.bottom).offset(16) + $0.centerX.equalToSuperview() + } + + self.backButton.snp.makeConstraints { + $0.bottom.equalToSuperview().inset(46) + $0.leading.trailing.equalToSuperview().inset(10) + $0.height.equalTo(52) + } + } + + @objc func backButtonDidTap() { + if self.navigationController == nil { + self.dismiss(animated: true) + } else { + self.navigationController?.popViewController(animated: true) + } + } + + private func bindEmail() { + guard let nameText = name else { return } + self.subTitleLabel.text = "\(nameText)님 반가워요!" + } + + func setLabelText(name: String?) { + self.name = name + } +} diff --git a/spot-37th-assignment/spot-37th-assignmentTests/LoginViewControllerTests.swift b/spot-37th-assignment/spot-37th-assignmentTests/LoginViewControllerTests.swift new file mode 100644 index 0000000..3f81ee7 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignmentTests/LoginViewControllerTests.swift @@ -0,0 +1,288 @@ +// +// LoginViewControllerTests.swift +// spot-37th-assignmentTests +// +// Created by 어재선 on 11/15/25. +// + +import XCTest +@testable import spot_37th_assignment + + +final class LoginViewControllerTests: XCTestCase { + + var sut: LoginViewController! // sut = System Under Test (테스트 대상) + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + try super.setUpWithError() + + // 각 테스트 전에 새로운 LoginViewController 인스턴스 생성 + sut = LoginViewController() + + // View를 메모리에 로드 (viewDidLoad 호출됨) + sut.loadViewIfNeeded() + + + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + + sut = nil + try super.tearDownWithError() + } + + // MARK: - 이메일 유효성 검사 테스트 + + func testValidEmail() { + // Given: 유효한 이메일 + let email = "jaesun@inha.ac.kr" + + // When: 이메일 유효성 검사 + let result = sut.isValidEmail(email: email) + + // Then: true를 반환해야 함 + XCTAssertTrue(result, "유효한 이메일 형식이 true를 반환해야 합니다") + } + + func testValidEmailWithGmailDomain() { + // Given + let email = "test@gmail.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "Gmail 형식이 유효해야 합니다") + } + + func testValidEmailWithUnderscore() { + // Given + let email = "test_user@example.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "언더스코어가 포함된 이메일이 유효해야 합니다") + } + + func testValidEmailWithDot() { + // Given + let email = "test.user@example.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "점이 포함된 이메일이 유효해야 합니다") + } + + func testValidEmailWithNumbers() { + // Given + let email = "user123@example.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "숫자가 포함된 이메일이 유효해야 합니다") + } + + func testInvalidEmailWithoutAtSign() { + // Given: @ 기호가 없는 이메일 + let email = "jaesuninha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then: false를 반환해야 함 + XCTAssertFalse(result, "@ 기호가 없는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithoutDomain() { + // Given + let email = "jaesun@" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "도메인이 없는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithoutExtension() { + // Given + let email = "jaesun@inha" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "확장자가 없는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithoutLocalPart() { + // Given + let email = "@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "로컬 부분이 없는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithEmptyString() { + // Given + let email = "" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "빈 문자열은 false를 반환해야 합니다") + } + + func testInvalidEmailWithSpace() { + // Given + let email = "jaesun @inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "공백이 포함된 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithMultipleAtSigns() { + // Given + let email = "jaesun@@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "여러 개의 @ 기호는 false를 반환해야 합니다") + } + + func testInvalidEmailStartingWithDot() { + // Given + let email = ".jaesun@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "점으로 시작하는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailEndingWithDot() { + // Given + let email = "jaesun.@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "점으로 끝나는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithConsecutiveDots() { + // Given + let email = "jae..sun@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "연속된 점이 있는 이메일은 false를 반환해야 합니다") + } + + func testInvalidEmailWithSpecialCharacters() { + // Given + let email = "jaesun#$%@inha.ac.kr" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertFalse(result, "허용되지 않은 특수문자는 false를 반환해야 합니다") + } + + // MARK: - Edge Cases (경계 케이스) + + func testEmailWithMinimumLength() { + // Given: 최소 길이의 유효한 이메일 + let email = "a@b.co" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "최소 길이의 유효한 이메일이어야 합니다") + } + + func testEmailWithLongExtension() { + // Given: 긴 확장자를 가진 이메일 + let email = "test@example.museum" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "긴 확장자를 가진 이메일이 유효해야 합니다") + } + + func testEmailWithSubdomain() { + // Given + let email = "test@mail.example.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "서브도메인을 포함한 이메일이 유효해야 합니다") + } + + // MARK: - 실제 사용 케이스 테스트 + + func testBaeminDomainEmail() { + // Given: 배민 실제 도메인 + let email = "developer@woowahan.com" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "배민 도메인 이메일이 유효해야 합니다") + } + + func testSOPTDomainEmail() { + // Given + let email = "jaesun@sopt.org" + + // When + let result = sut.isValidEmail(email: email) + + // Then + XCTAssertTrue(result, "SOPT 도메인 이메일이 유효해야 합니다") + } + + func testExample() throws { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + // Any test you write for XCTest can be annotated as throws and async. + // Mark your test throws to produce an unexpected failure when your test encounters an uncaught error. + // Mark your test async to allow awaiting for asynchronous code to complete. Check the results with assertions afterwards. + } + + func testPerformanceExample() throws { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git a/spot-37th-assignment/spot-37th-assignmentTests/spot_37th_assignmentTests.swift b/spot-37th-assignment/spot-37th-assignmentTests/spot_37th_assignmentTests.swift new file mode 100644 index 0000000..38c9019 --- /dev/null +++ b/spot-37th-assignment/spot-37th-assignmentTests/spot_37th_assignmentTests.swift @@ -0,0 +1,36 @@ +// +// spot_37th_assignmentTests.swift +// spot-37th-assignmentTests +// +// Created by 어재선 on 11/15/25. +// + +import XCTest +@testable import spot_37th_assignment + +final class spot_37th_assignmentTests: XCTestCase { + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + } + + func testExample() throws { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + // Any test you write for XCTest can be annotated as throws and async. + // Mark your test throws to produce an unexpected failure when your test encounters an uncaught error. + // Mark your test async to allow awaiting for asynchronous code to complete. Check the results with assertions afterwards. + } + + func testPerformanceExample() throws { + // This is an example of a performance test case. + measure { + // Put the code you want to measure the time of here. + } + } + +}