diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.pbxproj b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.pbxproj new file mode 100644 index 0000000..917949a --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.pbxproj @@ -0,0 +1,376 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + C8211B662BAA8187006182DB /* TravelGuideApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8211B652BAA8187006182DB /* TravelGuideApp.swift */; }; + C8211B682BAA8187006182DB /* WelcomScreenView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8211B672BAA8187006182DB /* WelcomScreenView.swift */; }; + C8211B6A2BAA8188006182DB /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C8211B692BAA8188006182DB /* Assets.xcassets */; }; + C8211B6D2BAA8188006182DB /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C8211B6C2BAA8188006182DB /* Preview Assets.xcassets */; }; + C8324A282BABFF1100AF016B /* Destination.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A272BABFF1100AF016B /* Destination.swift */; }; + C8324A2A2BABFF7F00AF016B /* DestinationListViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A292BABFF7F00AF016B /* DestinationListViewModel.swift */; }; + C8324A2C2BABFFD100AF016B /* DestinationViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A2B2BABFFD100AF016B /* DestinationViewModel.swift */; }; + C8324A2E2BAC008800AF016B /* DestinationDetailView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A2D2BAC008800AF016B /* DestinationDetailView.swift */; }; + C8324A322BAC010800AF016B /* DestinationsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A312BAC010800AF016B /* DestinationsView.swift */; }; + C8324A382BAC0EBA00AF016B /* XcodeString.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8324A372BAC0EBA00AF016B /* XcodeString.swift */; }; + C8540FF22BABD22C00C0769A /* Localizable.xcstrings in Resources */ = {isa = PBXBuildFile; fileRef = C8540FF12BABD22C00C0769A /* Localizable.xcstrings */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + C8211B622BAA8187006182DB /* TravelGuide.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TravelGuide.app; sourceTree = BUILT_PRODUCTS_DIR; }; + C8211B652BAA8187006182DB /* TravelGuideApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TravelGuideApp.swift; sourceTree = ""; }; + C8211B672BAA8187006182DB /* WelcomScreenView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WelcomScreenView.swift; sourceTree = ""; }; + C8211B692BAA8188006182DB /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + C8211B6C2BAA8188006182DB /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + C8324A272BABFF1100AF016B /* Destination.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Destination.swift; sourceTree = ""; }; + C8324A292BABFF7F00AF016B /* DestinationListViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DestinationListViewModel.swift; sourceTree = ""; }; + C8324A2B2BABFFD100AF016B /* DestinationViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DestinationViewModel.swift; sourceTree = ""; }; + C8324A2D2BAC008800AF016B /* DestinationDetailView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DestinationDetailView.swift; sourceTree = ""; }; + C8324A312BAC010800AF016B /* DestinationsView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DestinationsView.swift; sourceTree = ""; }; + C8324A372BAC0EBA00AF016B /* XcodeString.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = XcodeString.swift; sourceTree = ""; }; + C8540FF12BABD22C00C0769A /* Localizable.xcstrings */ = {isa = PBXFileReference; lastKnownFileType = text.json.xcstrings; path = Localizable.xcstrings; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + C8211B5F2BAA8187006182DB /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + C8211B592BAA8187006182DB = { + isa = PBXGroup; + children = ( + C8211B642BAA8187006182DB /* TravelGuide */, + C8211B632BAA8187006182DB /* Products */, + ); + sourceTree = ""; + }; + C8211B632BAA8187006182DB /* Products */ = { + isa = PBXGroup; + children = ( + C8211B622BAA8187006182DB /* TravelGuide.app */, + ); + name = Products; + sourceTree = ""; + }; + C8211B642BAA8187006182DB /* TravelGuide */ = { + isa = PBXGroup; + children = ( + C8324A272BABFF1100AF016B /* Destination.swift */, + C8324A292BABFF7F00AF016B /* DestinationListViewModel.swift */, + C8324A2B2BABFFD100AF016B /* DestinationViewModel.swift */, + C8324A2D2BAC008800AF016B /* DestinationDetailView.swift */, + C8324A312BAC010800AF016B /* DestinationsView.swift */, + C8211B652BAA8187006182DB /* TravelGuideApp.swift */, + C8211B672BAA8187006182DB /* WelcomScreenView.swift */, + C8324A372BAC0EBA00AF016B /* XcodeString.swift */, + C8540FF12BABD22C00C0769A /* Localizable.xcstrings */, + C8211B692BAA8188006182DB /* Assets.xcassets */, + C8211B6B2BAA8188006182DB /* Preview Content */, + ); + path = TravelGuide; + sourceTree = ""; + }; + C8211B6B2BAA8188006182DB /* Preview Content */ = { + isa = PBXGroup; + children = ( + C8211B6C2BAA8188006182DB /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C8211B612BAA8187006182DB /* TravelGuide */ = { + isa = PBXNativeTarget; + buildConfigurationList = C8211B702BAA8188006182DB /* Build configuration list for PBXNativeTarget "TravelGuide" */; + buildPhases = ( + C8211B5E2BAA8187006182DB /* Sources */, + C8211B5F2BAA8187006182DB /* Frameworks */, + C8211B602BAA8187006182DB /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = TravelGuide; + productName = TravelGuide; + productReference = C8211B622BAA8187006182DB /* TravelGuide.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + C8211B5A2BAA8187006182DB /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1530; + LastUpgradeCheck = 1530; + TargetAttributes = { + C8211B612BAA8187006182DB = { + CreatedOnToolsVersion = 15.3; + }; + }; + }; + buildConfigurationList = C8211B5D2BAA8187006182DB /* Build configuration list for PBXProject "TravelGuide" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + hi, + ); + mainGroup = C8211B592BAA8187006182DB; + productRefGroup = C8211B632BAA8187006182DB /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C8211B612BAA8187006182DB /* TravelGuide */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + C8211B602BAA8187006182DB /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + C8211B6D2BAA8188006182DB /* Preview Assets.xcassets in Resources */, + C8211B6A2BAA8188006182DB /* Assets.xcassets in Resources */, + C8540FF22BABD22C00C0769A /* Localizable.xcstrings in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + C8211B5E2BAA8187006182DB /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + C8324A2E2BAC008800AF016B /* DestinationDetailView.swift in Sources */, + C8324A322BAC010800AF016B /* DestinationsView.swift in Sources */, + C8211B682BAA8187006182DB /* WelcomScreenView.swift in Sources */, + C8211B662BAA8187006182DB /* TravelGuideApp.swift in Sources */, + C8324A282BABFF1100AF016B /* Destination.swift in Sources */, + C8324A2C2BABFFD100AF016B /* DestinationViewModel.swift in Sources */, + C8324A382BAC0EBA00AF016B /* XcodeString.swift in Sources */, + C8324A2A2BABFF7F00AF016B /* DestinationListViewModel.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + C8211B6E2BAA8188006182DB /* 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; + 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 = 17.4; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + C8211B6F2BAA8188006182DB /* 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"; + 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 = 17.4; + LOCALIZATION_PREFERS_STRING_CATALOGS = YES; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + C8211B712BAA8188006182DB /* 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_ASSET_PATHS = "\"TravelGuide/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.Ankit.TravelGuide; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + C8211B722BAA8188006182DB /* 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_ASSET_PATHS = "\"TravelGuide/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.Ankit.TravelGuide; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + C8211B5D2BAA8187006182DB /* Build configuration list for PBXProject "TravelGuide" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + C8211B6E2BAA8188006182DB /* Debug */, + C8211B6F2BAA8188006182DB /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + C8211B702BAA8188006182DB /* Build configuration list for PBXNativeTarget "TravelGuide" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + C8211B712BAA8188006182DB /* Debug */, + C8211B722BAA8188006182DB /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = C8211B5A2BAA8187006182DB /* Project object */; +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..919434a --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcuserdata/ankitmane.xcuserdatad/UserInterfaceState.xcuserstate b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcuserdata/ankitmane.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..1f95f30 Binary files /dev/null and b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/project.xcworkspace/xcuserdata/ankitmane.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 0000000..f6c5ce3 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,24 @@ + + + + + + + + + diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcschemes/xcschememanagement.plist b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..eb21593 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide.xcodeproj/xcuserdata/ankitmane.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + TravelGuide.xcscheme_^#shared#^_ + + orderHint + 0 + + + + diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AccentColor.colorset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 0000000..eb87897 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AppIcon.appiconset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..13613e3 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Alcatraz_Island_photo_Don_Ramey_Logan.jpg b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Alcatraz_Island_photo_Don_Ramey_Logan.jpg new file mode 100644 index 0000000..af23411 Binary files /dev/null and b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Alcatraz_Island_photo_Don_Ramey_Logan.jpg differ diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Contents.json new file mode 100644 index 0000000..df409dd --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/alcatraz_image_name.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "Alcatraz_Island_photo_Don_Ramey_Logan.jpg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/0940924B-A1E4-4A46-99ED-288BC89CEA59_1_105_c.jpeg b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/0940924B-A1E4-4A46-99ED-288BC89CEA59_1_105_c.jpeg new file mode 100644 index 0000000..5d47b2d Binary files /dev/null and b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/0940924B-A1E4-4A46-99ED-288BC89CEA59_1_105_c.jpeg differ diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/Contents.json new file mode 100644 index 0000000..6baebe3 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/big_sur_image_name.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "0940924B-A1E4-4A46-99ED-288BC89CEA59_1_105_c.jpeg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/63CDFB69-0EB8-410C-A4DC-9236CE2266E9_1_102_o.jpeg b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/63CDFB69-0EB8-410C-A4DC-9236CE2266E9_1_102_o.jpeg new file mode 100644 index 0000000..a86dcbb Binary files /dev/null and b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/63CDFB69-0EB8-410C-A4DC-9236CE2266E9_1_102_o.jpeg differ diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/Contents.json new file mode 100644 index 0000000..187b4e2 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/golden_gate_bridge_image_name.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "63CDFB69-0EB8-410C-A4DC-9236CE2266E9_1_102_o.jpeg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/Contents.json new file mode 100644 index 0000000..7a7e6ec --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "FB3F6E1A-69EE-414D-9BE8-A5FDA346C207_1_102_o.jpeg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/FB3F6E1A-69EE-414D-9BE8-A5FDA346C207_1_102_o.jpeg b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/FB3F6E1A-69EE-414D-9BE8-A5FDA346C207_1_102_o.jpeg new file mode 100644 index 0000000..a1eb3fe Binary files /dev/null and b/StringCatalogEnumSample/TravelGuide/TravelGuide/Assets.xcassets/twin_peaks_image_name.imageset/FB3F6E1A-69EE-414D-9BE8-A5FDA346C207_1_102_o.jpeg differ diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Destination.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/Destination.swift new file mode 100644 index 0000000..a6b177c --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Destination.swift @@ -0,0 +1,16 @@ +// +// Destination.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation + +struct Destination { + let name: String + let imageName: String + let description: String + let attractionsCount: Int + let attractions: [String] +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationDetailView.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationDetailView.swift new file mode 100644 index 0000000..02019e9 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationDetailView.swift @@ -0,0 +1,61 @@ +// +// DestinationDetailView.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation +import SwiftUI + +struct DestinationDetailView: View { + var destination: Destination + + var body: some View { + ZStack { + LinearGradient(gradient: Gradient(colors: [.blue, .white]), + startPoint: .topLeading, + endPoint: .bottomTrailing) + .edgesIgnoringSafeArea(.all) + + ScrollView { + VStack { + Image(destination.imageName) // Ensure you have this image in your assets + .resizable() + .frame(width: 250, height: 250) + .scaledToFit() + .cornerRadius(10) + .shadow(radius: 5) + .padding() + + Text(destination.name) + .font(.largeTitle) + .fontWeight(.bold) + .padding([.top, .bottom], 5) + + Text(destination.description) + .font(.body) + .padding() + + VStack(alignment: .leading) { + Text(String.localizedStringWithFormat(NSLocalizedString(XCS.lldAttractions.rawValue, comment: ""), Int64(destination.attractionsCount))) + .font(.headline) + .padding([.top, .bottom, .leading]) + + ForEach(destination.attractions, id: \.self) { attraction in + Text("• \(attraction)") + .padding([.bottom, .leading]) + } + } + .frame(maxWidth: .infinity, alignment: .leading) + .background(Color.black.opacity(0.2)) + .cornerRadius(10) + .shadow(radius: 5) + } + .padding() + } + .navigationTitle(destination.name) + .navigationBarTitleDisplayMode(.inline) + } + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationListViewModel.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationListViewModel.swift new file mode 100644 index 0000000..61ef4cb --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationListViewModel.swift @@ -0,0 +1,58 @@ +// +// DestinationListViewModel.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation +class DestinationListViewModel: ObservableObject { + @Published var destinations: [Destination] = [] + + // Initializer or function to load destinations + func loadDestinations() { + + destinations = [ + Destination( + name: XCS.bigSur.string, + imageName: "big_sur_image_name", + description: XCS.bigSureDesc.string, + attractionsCount: 3, + attractions: [ + XCS.bigSurAttraction1.string, + XCS.bigSurAttraction2.string, + XCS.bigSurAttraction3.string + ] + ), + Destination( + name: XCS.goldenGateBridge.string, + imageName: "golden_gate_bridge_image_name", + description: XCS.goldenGateBridgeDesc.string, + attractionsCount: 1, + attractions: [ + XCS.goldenGateBridgeAttraction.string + ] + ), + Destination( + name: XCS.alcatraz.string, + imageName: "alcatraz_image_name", + description: XCS.alcatrazDesc.string, + attractionsCount: 2, + attractions: [ + XCS.alcatrazAttraction1.string, + XCS.alcatrazAttraction2.string + ] + ), + Destination( + name: XCS.twinPeaks.string, + imageName: "twin_peaks_image_name", + description: XCS.twinPeaksDesc.string, + attractionsCount: 1, + attractions: [ + XCS.twinPeaksAttraction.string + ] + ) + ] + + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationViewModel.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationViewModel.swift new file mode 100644 index 0000000..0889a08 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationViewModel.swift @@ -0,0 +1,15 @@ +// +// DestinationViewModel.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation +class DestinationViewModel: ObservableObject { + @Published var destination: Destination + + init(destination: Destination) { + self.destination = destination + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationsView.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationsView.swift new file mode 100644 index 0000000..9cdc19c --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/DestinationsView.swift @@ -0,0 +1,53 @@ +// +// DestinationsView.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation +import SwiftUI + +struct DestinationsView: View { + @ObservedObject var viewModel = DestinationListViewModel() + + var body: some View { + ZStack { + LinearGradient(gradient: Gradient(colors: [.blue, .white]), + startPoint: .topLeading, + endPoint: .bottomTrailing) + .edgesIgnoringSafeArea(.all) + + ScrollView { + LazyVStack(spacing: 0) { + ForEach(viewModel.destinations, id: \.name) { destination in + NavigationLink(destination: DestinationDetailView(destination: destination)) { + HStack { + Image(destination.imageName) // Ensure you have these images in your assets + .resizable() + .frame(width: 50, height: 50) + .cornerRadius(10) + Text(destination.name) + Spacer() + Image(systemName: "chevron.right") + } + .padding() + .frame(maxWidth: .infinity, alignment: .leading) + .background(Color.white.opacity(0.5)) + .cornerRadius(10) + .shadow(radius: 1) + .padding(.horizontal) + .padding(.vertical, 4) + } + .buttonStyle(PlainButtonStyle()) // Remove the button highlight effect on tap + } + } + } + .navigationTitle(XCS.travelDestinations.string) + } + .onAppear { + viewModel.loadDestinations() // Load destinations when the view appears + } + } +} + diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/File.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/File.swift new file mode 100644 index 0000000..129533c --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/File.swift @@ -0,0 +1,8 @@ +// +// File.swift +// TravelGuide +// +// Created by Ankit Mane on 3/20/24. +// + +import Foundation diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Localizable.xcstrings b/StringCatalogEnumSample/TravelGuide/TravelGuide/Localizable.xcstrings new file mode 100644 index 0000000..9e1deac --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Localizable.xcstrings @@ -0,0 +1,345 @@ +{ + "sourceLanguage" : "en", + "strings" : { + " %lld Attractions:" : { + "extractionState" : "stale", + "localizations" : { + "en" : { + "variations" : { + "plural" : { + "one" : { + "stringUnit" : { + "state" : "translated", + "value" : " %lld Attraction:" + } + }, + "other" : { + "stringUnit" : { + "state" : "new", + "value" : " %lld Attractions:" + } + } + } + } + }, + "hi" : { + "variations" : { + "plural" : { + "one" : { + "stringUnit" : { + "state" : "translated", + "value" : "%lld आकर्षण:" + } + }, + "other" : { + "stringUnit" : { + "state" : "translated", + "value" : " %lld आकर्षण:" + } + } + } + } + } + } + }, + "• %@" : { + "localizations" : { + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : ". %@" + } + } + } + }, + "Alcatraz" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Alcatraz" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "अलकाट्राज़" + } + } + } + }, + "AlcatrazAttraction1" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Cellhouse" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "सेलहाउस" + } + } + } + }, + "AlcatrazAttraction2" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Alcatraz Island" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "अलकाट्राज़ द्वीप" + } + } + } + }, + "AlcatrazDesc" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "An island offering a glimpse into the prison that once held some of the United States' most notorious criminals." + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "एक द्वीप जो उस जेल की झलक पेश करता है जिसमें कभी संयुक्त राज्य अमेरिका के कुछ सबसे कुख्यात अपराधियों को रखा जाता था।" + } + } + } + }, + "BigSur" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Big Sur" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "बिग सुर" + } + } + } + }, + "BigSurAttraction1" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Bixby Creek Bridge" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "बिक्सबी क्रीक ब्रिज" + } + } + } + }, + "BigSurAttraction2" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Pfeiffer Beach" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "फ़िफ़र बीच" + } + } + } + }, + "BigSurAttraction3" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "McWay Falls" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "मैक्वे फॉल्स" + } + } + } + }, + "BigSureDesc" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "A scenic stretch of California's coast known for its views, parks, and outdoor activities" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "कैलिफ़ोर्निया के तट का एक सुंदर विस्तार जो अपने दृश्यों, पार्कों और बाहरी गतिविधियों के लिए जाना जाता है" + } + } + } + }, + "Get travel destinations" : { + "extractionState" : "manual", + "localizations" : { + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "यात्रा गंतव्य प्राप्त करें" + } + } + } + }, + "GoldenGateBridge" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Golden Gate Bridge" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "गोल्डन गेट ब्रिज" + } + } + } + }, + "GoldenGateBridgeAttraction" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Bridge Viewpoints" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "ब्रिज व्यूप्वाइंट" + } + } + } + }, + "GoldenGateBridgeDesc" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "An iconic suspension bridge and one of the most internationally recognized symbols of San Francisco" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "एक प्रतिष्ठित सस्पेंशन ब्रिज और सैन फ्रांसिस्को के सबसे अंतरराष्ट्रीय स्तर पर मान्यता प्राप्त प्रतीकों में से एक" + } + } + } + }, + "Travel Destinations" : { + "extractionState" : "manual", + "localizations" : { + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "\nयात्रा स्थल" + } + } + } + }, + "TwinPeaks" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Twin Peaks" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "दो चोटियां" + } + } + } + }, + "TwinPeaksAttraction" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Twin Peaks Summit" + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "ट्विन पीक्स समिट" + } + } + } + }, + "TwinPeaksDesc" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Offers some of the best views of San Francisco, providing a panoramic lookout over the city." + } + }, + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "यह सैन फ़्रांसिस्को के कुछ बेहतरीन दृश्य प्रस्तुत करता है, जो शहर का मनोरम दृश्य प्रदान करता है।" + } + } + } + }, + "Welcome to San Francisco" : { + "extractionState" : "manual", + "localizations" : { + "hi" : { + "stringUnit" : { + "state" : "translated", + "value" : "सैन फ्रांसिस्को में आपका स्वागत है" + } + } + } + } + }, + "version" : "1.0" +} \ No newline at end of file diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/Preview Content/Preview Assets.xcassets/Contents.json b/StringCatalogEnumSample/TravelGuide/TravelGuide/Preview Content/Preview Assets.xcassets/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/Preview Content/Preview Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/TravelGuideApp.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/TravelGuideApp.swift new file mode 100644 index 0000000..99f021b --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/TravelGuideApp.swift @@ -0,0 +1,17 @@ +// +// TravelGuideApp.swift +// TravelGuide +// +// Created by Ankit Mane on 3/19/24. +// + +import SwiftUI + +@main +struct TravelGuideApp: App { + var body: some Scene { + WindowGroup { + WelcomScreenView() + } + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/WelcomScreenView.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/WelcomScreenView.swift new file mode 100644 index 0000000..d4a9ff5 --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/WelcomScreenView.swift @@ -0,0 +1,35 @@ +import SwiftUI + +struct WelcomScreenView: View { + var body: some View { + NavigationView { + ZStack { + LinearGradient(gradient: Gradient(colors: [.blue, .white]), + startPoint: .topLeading, + endPoint: .bottomTrailing) + .edgesIgnoringSafeArea(.all) + + VStack { + Text(XCS.welcomeToSanFrancisco.string) + .font(.system(size: 30)) + .foregroundColor(.black) + .padding(.bottom, 50) + + NavigationLink(destination: DestinationsView()) { + ZStack { + Rectangle() + .fill(.black) + .frame(width: 250, height: 40) + .cornerRadius(15) + .shadow(radius: 10) + Text(XCS.getTravelDestinations.string) + .foregroundColor(.white) + } + } + } + } + } + .navigationBarTitleDisplayMode(.inline) + .accentColor(.black) + } +} diff --git a/StringCatalogEnumSample/TravelGuide/TravelGuide/XcodeString.swift b/StringCatalogEnumSample/TravelGuide/TravelGuide/XcodeString.swift new file mode 100644 index 0000000..9fb259e --- /dev/null +++ b/StringCatalogEnumSample/TravelGuide/TravelGuide/XcodeString.swift @@ -0,0 +1,61 @@ +// This file is generated by XcodeStringEnum. Please do *NOT* update it manually. +// As a common practice, swiftLint is disabled for generated files. +// swiftlint:disable all + +import SwiftUI + +/// Makes it a bit easier to type. +typealias XCS = XcodeStringKey + +/// Generated by StringCatalogEnum, this enum contains all existing Strin Category keys. +enum XcodeStringKey: String, CaseIterable { + + // MARK: - The following cases should be manually replaced in your codebase. + + /// 'en': "A scenic stretch of California's coast known for its views, parks, and outdoor activities" + case bigSureDesc = "BigSureDesc" + /// 'en': "Alcatraz Island" + case alcatrazAttraction2 = "AlcatrazAttraction2" + /// 'en': "Alcatraz" + case alcatraz = "Alcatraz" + /// 'en': "An iconic suspension bridge and one of the most internationally recognized symbols of San Francisco" + case goldenGateBridgeDesc = "GoldenGateBridgeDesc" + /// 'en': "An island offering a glimpse into the prison that once held some of the United States' most notorious criminals." + case alcatrazDesc = "AlcatrazDesc" + /// 'en': "Big Sur" + case bigSur = "BigSur" + /// 'en': "Bixby Creek Bridge" + case bigSurAttraction1 = "BigSurAttraction1" + /// 'en': "Bridge Viewpoints" + case goldenGateBridgeAttraction = "GoldenGateBridgeAttraction" + /// 'en': "Cellhouse" + case alcatrazAttraction1 = "AlcatrazAttraction1" + /// 'en': "Golden Gate Bridge" + case goldenGateBridge = "GoldenGateBridge" + /// 'en': "McWay Falls" + case bigSurAttraction3 = "BigSurAttraction3" + /// 'en': "Offers some of the best views of San Francisco, providing a panoramic lookout over the city." + case twinPeaksDesc = "TwinPeaksDesc" + /// 'en': "Pfeiffer Beach" + case bigSurAttraction2 = "BigSurAttraction2" + /// 'en': "Twin Peaks Summit" + case twinPeaksAttraction = "TwinPeaksAttraction" + /// 'en': "Twin Peaks" + case twinPeaks = "TwinPeaks" + /// No localizations available + case getTravelDestinations = "Get travel destinations" + /// No localizations available + case lldAttractions = " %lld Attractions:" + /// No localizations available + case travelDestinations = "Travel Destinations" + /// No localizations available + case welcomeToSanFrancisco = "Welcome to San Francisco" + + /// Usage: `SwiftUI.Text(XCS.yourStringCatalogKey.key)` + var key: LocalizedStringKey { LocalizedStringKey(rawValue) } + + var string: String { NSLocalizedString(self.rawValue, comment: "Generated localization from String Catalog key: \(key)") } + + // var text: String.LocalizationValue { String.LocalizationValue(rawValue) } +} +// swiftlint:enable all \ No newline at end of file