├── README.md ├── food.xcodeproj ├── gif.gif ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist ├── ui.png └── xcuserdata │ └── abir.xcuserdatad │ └── xcschemes │ └── xcschememanagement.plist ├── food ├── Assets.xcassets │ ├── AccentColor.colorset │ │ └── Contents.json │ ├── AppIcon.appiconset │ │ └── Contents.json │ ├── Contents.json │ ├── GrayColor.colorset │ │ └── Contents.json │ ├── Icons │ │ ├── Contents.json │ │ ├── filter.imageset │ │ │ ├── Contents.json │ │ │ └── filter.pdf │ │ ├── like.imageset │ │ │ ├── Contents.json │ │ │ └── like.pdf │ │ ├── like_fill.imageset │ │ │ ├── Contents.json │ │ │ └── like_fill.pdf │ │ ├── menu.imageset │ │ │ ├── Contents.json │ │ │ └── menu.pdf │ │ ├── notifications.imageset │ │ │ ├── Contents.json │ │ │ └── notifications.pdf │ │ ├── search.imageset │ │ │ ├── Contents.json │ │ │ └── search.pdf │ │ ├── serving.imageset │ │ │ ├── Contents.json │ │ │ └── serving.pdf │ │ ├── star.imageset │ │ │ ├── Contents.json │ │ │ └── star.pdf │ │ └── time.imageset │ │ │ ├── Contents.json │ │ │ └── time.pdf │ ├── Images │ │ ├── Contents.json │ │ ├── fresh_recipe_1.imageset │ │ │ ├── Contents.json │ │ │ └── fresh_recipe_1.png │ │ ├── fresh_recipe_2.imageset │ │ │ ├── Contents.json │ │ │ └── fresh_recipe_2.png │ │ ├── reco_1.imageset │ │ │ ├── Contents.json │ │ │ └── reco_1.png │ │ ├── reco_2.imageset │ │ │ ├── Contents.json │ │ │ └── reco_2.png │ │ └── reco_3.imageset │ │ │ ├── Contents.json │ │ │ └── reco_3.png │ ├── LightGrayColor.colorset │ │ └── Contents.json │ ├── PrimaryColor.colorset │ │ └── Contents.json │ ├── SecondaryColor.colorset │ │ └── Contents.json │ └── TextColor.colorset │ │ └── Contents.json ├── ContentView.swift ├── Info.plist ├── Preview Content │ └── Preview Assets.xcassets │ │ └── Contents.json ├── Views │ ├── FreshRecipesView.swift │ ├── HomeNavBarView.swift │ ├── HomeView.swift │ ├── RecommendedRecipeCardView.swift │ ├── SearchAndFilterView.swift │ └── SectionTitleView.swift ├── fonts │ ├── Hellix-Bold.ttf │ ├── Hellix-Medium.ttf │ ├── Hellix-Regular.ttf │ ├── Hellix-SemiBold.ttf │ └── Hellix-Thin.ttf └── foodApp.swift ├── foodTests ├── Info.plist └── foodTests.swift └── foodUITests ├── Info.plist └── foodUITests.swift /README.md: -------------------------------------------------------------------------------- 1 | # Food Delivery App Home Page UI - SwiftUI 2 | 3 | ## [Watch it on YouTube](https://youtu.be/n4EuMTY3ehc) 4 | 5 | By using SwiftUI we design Food Delivery App home page, which contains a search bar with a filter option at the top. Then a horizontal list of today's fresh recipes at the end recommended some recipes to the user. 6 | 7 | ### Food Delivery App Home Page Final UI 8 | 9 | 10 | ![App UI](https://i.imgur.com/BP2WwpG.png) 11 | -------------------------------------------------------------------------------- /food.xcodeproj/gif.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food.xcodeproj/gif.gif -------------------------------------------------------------------------------- /food.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 8821892925BEC29900820A7E /* foodApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821892825BEC29900820A7E /* foodApp.swift */; }; 11 | 8821892B25BEC29900820A7E /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821892A25BEC29900820A7E /* ContentView.swift */; }; 12 | 8821892D25BEC29B00820A7E /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 8821892C25BEC29B00820A7E /* Assets.xcassets */; }; 13 | 8821893025BEC29B00820A7E /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 8821892F25BEC29B00820A7E /* Preview Assets.xcassets */; }; 14 | 8821893B25BEC29B00820A7E /* foodTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821893A25BEC29B00820A7E /* foodTests.swift */; }; 15 | 8821894625BEC29B00820A7E /* foodUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821894525BEC29B00820A7E /* foodUITests.swift */; }; 16 | 8821895825BEC82400820A7E /* HomeNavBarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821895725BEC82400820A7E /* HomeNavBarView.swift */; }; 17 | 8821896525BEC93500820A7E /* Hellix-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8821896025BEC93500820A7E /* Hellix-Regular.ttf */; }; 18 | 8821896625BEC93500820A7E /* Hellix-Thin.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8821896125BEC93500820A7E /* Hellix-Thin.ttf */; }; 19 | 8821896725BEC93500820A7E /* Hellix-Bold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8821896225BEC93500820A7E /* Hellix-Bold.ttf */; }; 20 | 8821896825BEC93500820A7E /* Hellix-Medium.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8821896325BEC93500820A7E /* Hellix-Medium.ttf */; }; 21 | 8821896925BEC93500820A7E /* Hellix-SemiBold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 8821896425BEC93500820A7E /* Hellix-SemiBold.ttf */; }; 22 | 8821896E25BEFE3C00820A7E /* SearchAndFilterView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821896D25BEFE3C00820A7E /* SearchAndFilterView.swift */; }; 23 | 8821897325BF073800820A7E /* FreshRecipesView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821897225BF073800820A7E /* FreshRecipesView.swift */; }; 24 | 8821897825BF257E00820A7E /* SectionTitleView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821897725BF257E00820A7E /* SectionTitleView.swift */; }; 25 | 8821897D25BF2D7600820A7E /* RecommendedRecipeCardView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821897C25BF2D7600820A7E /* RecommendedRecipeCardView.swift */; }; 26 | 8821898225BF2DE800820A7E /* HomeView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8821898125BF2DE800820A7E /* HomeView.swift */; }; 27 | 884FDFB625C403E500B05042 /* gif.gif in Resources */ = {isa = PBXBuildFile; fileRef = 884FDFB525C403E500B05042 /* gif.gif */; }; 28 | /* End PBXBuildFile section */ 29 | 30 | /* Begin PBXContainerItemProxy section */ 31 | 8821893725BEC29B00820A7E /* PBXContainerItemProxy */ = { 32 | isa = PBXContainerItemProxy; 33 | containerPortal = 8821891D25BEC29900820A7E /* Project object */; 34 | proxyType = 1; 35 | remoteGlobalIDString = 8821892425BEC29900820A7E; 36 | remoteInfo = food; 37 | }; 38 | 8821894225BEC29B00820A7E /* PBXContainerItemProxy */ = { 39 | isa = PBXContainerItemProxy; 40 | containerPortal = 8821891D25BEC29900820A7E /* Project object */; 41 | proxyType = 1; 42 | remoteGlobalIDString = 8821892425BEC29900820A7E; 43 | remoteInfo = food; 44 | }; 45 | /* End PBXContainerItemProxy section */ 46 | 47 | /* Begin PBXFileReference section */ 48 | 8821892525BEC29900820A7E /* food.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = food.app; sourceTree = BUILT_PRODUCTS_DIR; }; 49 | 8821892825BEC29900820A7E /* foodApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = foodApp.swift; sourceTree = ""; }; 50 | 8821892A25BEC29900820A7E /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; 51 | 8821892C25BEC29B00820A7E /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 52 | 8821892F25BEC29B00820A7E /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; 53 | 8821893125BEC29B00820A7E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 54 | 8821893625BEC29B00820A7E /* foodTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = foodTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 55 | 8821893A25BEC29B00820A7E /* foodTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = foodTests.swift; sourceTree = ""; }; 56 | 8821893C25BEC29B00820A7E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 57 | 8821894125BEC29B00820A7E /* foodUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = foodUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 58 | 8821894525BEC29B00820A7E /* foodUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = foodUITests.swift; sourceTree = ""; }; 59 | 8821894725BEC29B00820A7E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 60 | 8821895725BEC82400820A7E /* HomeNavBarView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HomeNavBarView.swift; sourceTree = ""; }; 61 | 8821896025BEC93500820A7E /* Hellix-Regular.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Hellix-Regular.ttf"; sourceTree = ""; }; 62 | 8821896125BEC93500820A7E /* Hellix-Thin.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Hellix-Thin.ttf"; sourceTree = ""; }; 63 | 8821896225BEC93500820A7E /* Hellix-Bold.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Hellix-Bold.ttf"; sourceTree = ""; }; 64 | 8821896325BEC93500820A7E /* Hellix-Medium.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Hellix-Medium.ttf"; sourceTree = ""; }; 65 | 8821896425BEC93500820A7E /* Hellix-SemiBold.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = "Hellix-SemiBold.ttf"; sourceTree = ""; }; 66 | 8821896D25BEFE3C00820A7E /* SearchAndFilterView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SearchAndFilterView.swift; sourceTree = ""; }; 67 | 8821897225BF073800820A7E /* FreshRecipesView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FreshRecipesView.swift; sourceTree = ""; }; 68 | 8821897725BF257E00820A7E /* SectionTitleView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SectionTitleView.swift; sourceTree = ""; }; 69 | 8821897C25BF2D7600820A7E /* RecommendedRecipeCardView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RecommendedRecipeCardView.swift; sourceTree = ""; }; 70 | 8821898125BF2DE800820A7E /* HomeView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HomeView.swift; sourceTree = ""; }; 71 | 884FDFB525C403E500B05042 /* gif.gif */ = {isa = PBXFileReference; lastKnownFileType = image.gif; path = gif.gif; sourceTree = ""; }; 72 | /* End PBXFileReference section */ 73 | 74 | /* Begin PBXFrameworksBuildPhase section */ 75 | 8821892225BEC29900820A7E /* Frameworks */ = { 76 | isa = PBXFrameworksBuildPhase; 77 | buildActionMask = 2147483647; 78 | files = ( 79 | ); 80 | runOnlyForDeploymentPostprocessing = 0; 81 | }; 82 | 8821893325BEC29B00820A7E /* Frameworks */ = { 83 | isa = PBXFrameworksBuildPhase; 84 | buildActionMask = 2147483647; 85 | files = ( 86 | ); 87 | runOnlyForDeploymentPostprocessing = 0; 88 | }; 89 | 8821893E25BEC29B00820A7E /* Frameworks */ = { 90 | isa = PBXFrameworksBuildPhase; 91 | buildActionMask = 2147483647; 92 | files = ( 93 | ); 94 | runOnlyForDeploymentPostprocessing = 0; 95 | }; 96 | /* End PBXFrameworksBuildPhase section */ 97 | 98 | /* Begin PBXGroup section */ 99 | 8821891C25BEC29900820A7E = { 100 | isa = PBXGroup; 101 | children = ( 102 | 884FDFB525C403E500B05042 /* gif.gif */, 103 | 8821892725BEC29900820A7E /* food */, 104 | 8821893925BEC29B00820A7E /* foodTests */, 105 | 8821894425BEC29B00820A7E /* foodUITests */, 106 | 8821892625BEC29900820A7E /* Products */, 107 | ); 108 | sourceTree = ""; 109 | }; 110 | 8821892625BEC29900820A7E /* Products */ = { 111 | isa = PBXGroup; 112 | children = ( 113 | 8821892525BEC29900820A7E /* food.app */, 114 | 8821893625BEC29B00820A7E /* foodTests.xctest */, 115 | 8821894125BEC29B00820A7E /* foodUITests.xctest */, 116 | ); 117 | name = Products; 118 | sourceTree = ""; 119 | }; 120 | 8821892725BEC29900820A7E /* food */ = { 121 | isa = PBXGroup; 122 | children = ( 123 | 8821895F25BEC8EE00820A7E /* fonts */, 124 | 8821895625BEC81300820A7E /* Views */, 125 | 8821892825BEC29900820A7E /* foodApp.swift */, 126 | 8821892A25BEC29900820A7E /* ContentView.swift */, 127 | 8821892C25BEC29B00820A7E /* Assets.xcassets */, 128 | 8821893125BEC29B00820A7E /* Info.plist */, 129 | 8821892E25BEC29B00820A7E /* Preview Content */, 130 | ); 131 | path = food; 132 | sourceTree = ""; 133 | }; 134 | 8821892E25BEC29B00820A7E /* Preview Content */ = { 135 | isa = PBXGroup; 136 | children = ( 137 | 8821892F25BEC29B00820A7E /* Preview Assets.xcassets */, 138 | ); 139 | path = "Preview Content"; 140 | sourceTree = ""; 141 | }; 142 | 8821893925BEC29B00820A7E /* foodTests */ = { 143 | isa = PBXGroup; 144 | children = ( 145 | 8821893A25BEC29B00820A7E /* foodTests.swift */, 146 | 8821893C25BEC29B00820A7E /* Info.plist */, 147 | ); 148 | path = foodTests; 149 | sourceTree = ""; 150 | }; 151 | 8821894425BEC29B00820A7E /* foodUITests */ = { 152 | isa = PBXGroup; 153 | children = ( 154 | 8821894525BEC29B00820A7E /* foodUITests.swift */, 155 | 8821894725BEC29B00820A7E /* Info.plist */, 156 | ); 157 | path = foodUITests; 158 | sourceTree = ""; 159 | }; 160 | 8821895625BEC81300820A7E /* Views */ = { 161 | isa = PBXGroup; 162 | children = ( 163 | 8821895725BEC82400820A7E /* HomeNavBarView.swift */, 164 | 8821896D25BEFE3C00820A7E /* SearchAndFilterView.swift */, 165 | 8821897225BF073800820A7E /* FreshRecipesView.swift */, 166 | 8821897725BF257E00820A7E /* SectionTitleView.swift */, 167 | 8821897C25BF2D7600820A7E /* RecommendedRecipeCardView.swift */, 168 | 8821898125BF2DE800820A7E /* HomeView.swift */, 169 | ); 170 | path = Views; 171 | sourceTree = ""; 172 | }; 173 | 8821895F25BEC8EE00820A7E /* fonts */ = { 174 | isa = PBXGroup; 175 | children = ( 176 | 8821896225BEC93500820A7E /* Hellix-Bold.ttf */, 177 | 8821896325BEC93500820A7E /* Hellix-Medium.ttf */, 178 | 8821896025BEC93500820A7E /* Hellix-Regular.ttf */, 179 | 8821896425BEC93500820A7E /* Hellix-SemiBold.ttf */, 180 | 8821896125BEC93500820A7E /* Hellix-Thin.ttf */, 181 | ); 182 | path = fonts; 183 | sourceTree = ""; 184 | }; 185 | /* End PBXGroup section */ 186 | 187 | /* Begin PBXNativeTarget section */ 188 | 8821892425BEC29900820A7E /* food */ = { 189 | isa = PBXNativeTarget; 190 | buildConfigurationList = 8821894A25BEC29B00820A7E /* Build configuration list for PBXNativeTarget "food" */; 191 | buildPhases = ( 192 | 8821892125BEC29900820A7E /* Sources */, 193 | 8821892225BEC29900820A7E /* Frameworks */, 194 | 8821892325BEC29900820A7E /* Resources */, 195 | ); 196 | buildRules = ( 197 | ); 198 | dependencies = ( 199 | ); 200 | name = food; 201 | productName = food; 202 | productReference = 8821892525BEC29900820A7E /* food.app */; 203 | productType = "com.apple.product-type.application"; 204 | }; 205 | 8821893525BEC29B00820A7E /* foodTests */ = { 206 | isa = PBXNativeTarget; 207 | buildConfigurationList = 8821894D25BEC29B00820A7E /* Build configuration list for PBXNativeTarget "foodTests" */; 208 | buildPhases = ( 209 | 8821893225BEC29B00820A7E /* Sources */, 210 | 8821893325BEC29B00820A7E /* Frameworks */, 211 | 8821893425BEC29B00820A7E /* Resources */, 212 | ); 213 | buildRules = ( 214 | ); 215 | dependencies = ( 216 | 8821893825BEC29B00820A7E /* PBXTargetDependency */, 217 | ); 218 | name = foodTests; 219 | productName = foodTests; 220 | productReference = 8821893625BEC29B00820A7E /* foodTests.xctest */; 221 | productType = "com.apple.product-type.bundle.unit-test"; 222 | }; 223 | 8821894025BEC29B00820A7E /* foodUITests */ = { 224 | isa = PBXNativeTarget; 225 | buildConfigurationList = 8821895025BEC29B00820A7E /* Build configuration list for PBXNativeTarget "foodUITests" */; 226 | buildPhases = ( 227 | 8821893D25BEC29B00820A7E /* Sources */, 228 | 8821893E25BEC29B00820A7E /* Frameworks */, 229 | 8821893F25BEC29B00820A7E /* Resources */, 230 | ); 231 | buildRules = ( 232 | ); 233 | dependencies = ( 234 | 8821894325BEC29B00820A7E /* PBXTargetDependency */, 235 | ); 236 | name = foodUITests; 237 | productName = foodUITests; 238 | productReference = 8821894125BEC29B00820A7E /* foodUITests.xctest */; 239 | productType = "com.apple.product-type.bundle.ui-testing"; 240 | }; 241 | /* End PBXNativeTarget section */ 242 | 243 | /* Begin PBXProject section */ 244 | 8821891D25BEC29900820A7E /* Project object */ = { 245 | isa = PBXProject; 246 | attributes = { 247 | LastSwiftUpdateCheck = 1230; 248 | LastUpgradeCheck = 1230; 249 | TargetAttributes = { 250 | 8821892425BEC29900820A7E = { 251 | CreatedOnToolsVersion = 12.3; 252 | }; 253 | 8821893525BEC29B00820A7E = { 254 | CreatedOnToolsVersion = 12.3; 255 | TestTargetID = 8821892425BEC29900820A7E; 256 | }; 257 | 8821894025BEC29B00820A7E = { 258 | CreatedOnToolsVersion = 12.3; 259 | TestTargetID = 8821892425BEC29900820A7E; 260 | }; 261 | }; 262 | }; 263 | buildConfigurationList = 8821892025BEC29900820A7E /* Build configuration list for PBXProject "food" */; 264 | compatibilityVersion = "Xcode 9.3"; 265 | developmentRegion = en; 266 | hasScannedForEncodings = 0; 267 | knownRegions = ( 268 | en, 269 | Base, 270 | ); 271 | mainGroup = 8821891C25BEC29900820A7E; 272 | productRefGroup = 8821892625BEC29900820A7E /* Products */; 273 | projectDirPath = ""; 274 | projectRoot = ""; 275 | targets = ( 276 | 8821892425BEC29900820A7E /* food */, 277 | 8821893525BEC29B00820A7E /* foodTests */, 278 | 8821894025BEC29B00820A7E /* foodUITests */, 279 | ); 280 | }; 281 | /* End PBXProject section */ 282 | 283 | /* Begin PBXResourcesBuildPhase section */ 284 | 8821892325BEC29900820A7E /* Resources */ = { 285 | isa = PBXResourcesBuildPhase; 286 | buildActionMask = 2147483647; 287 | files = ( 288 | 8821896725BEC93500820A7E /* Hellix-Bold.ttf in Resources */, 289 | 884FDFB625C403E500B05042 /* gif.gif in Resources */, 290 | 8821893025BEC29B00820A7E /* Preview Assets.xcassets in Resources */, 291 | 8821896625BEC93500820A7E /* Hellix-Thin.ttf in Resources */, 292 | 8821896925BEC93500820A7E /* Hellix-SemiBold.ttf in Resources */, 293 | 8821896825BEC93500820A7E /* Hellix-Medium.ttf in Resources */, 294 | 8821896525BEC93500820A7E /* Hellix-Regular.ttf in Resources */, 295 | 8821892D25BEC29B00820A7E /* Assets.xcassets in Resources */, 296 | ); 297 | runOnlyForDeploymentPostprocessing = 0; 298 | }; 299 | 8821893425BEC29B00820A7E /* Resources */ = { 300 | isa = PBXResourcesBuildPhase; 301 | buildActionMask = 2147483647; 302 | files = ( 303 | ); 304 | runOnlyForDeploymentPostprocessing = 0; 305 | }; 306 | 8821893F25BEC29B00820A7E /* Resources */ = { 307 | isa = PBXResourcesBuildPhase; 308 | buildActionMask = 2147483647; 309 | files = ( 310 | ); 311 | runOnlyForDeploymentPostprocessing = 0; 312 | }; 313 | /* End PBXResourcesBuildPhase section */ 314 | 315 | /* Begin PBXSourcesBuildPhase section */ 316 | 8821892125BEC29900820A7E /* Sources */ = { 317 | isa = PBXSourcesBuildPhase; 318 | buildActionMask = 2147483647; 319 | files = ( 320 | 8821895825BEC82400820A7E /* HomeNavBarView.swift in Sources */, 321 | 8821897D25BF2D7600820A7E /* RecommendedRecipeCardView.swift in Sources */, 322 | 8821892B25BEC29900820A7E /* ContentView.swift in Sources */, 323 | 8821896E25BEFE3C00820A7E /* SearchAndFilterView.swift in Sources */, 324 | 8821897325BF073800820A7E /* FreshRecipesView.swift in Sources */, 325 | 8821898225BF2DE800820A7E /* HomeView.swift in Sources */, 326 | 8821892925BEC29900820A7E /* foodApp.swift in Sources */, 327 | 8821897825BF257E00820A7E /* SectionTitleView.swift in Sources */, 328 | ); 329 | runOnlyForDeploymentPostprocessing = 0; 330 | }; 331 | 8821893225BEC29B00820A7E /* Sources */ = { 332 | isa = PBXSourcesBuildPhase; 333 | buildActionMask = 2147483647; 334 | files = ( 335 | 8821893B25BEC29B00820A7E /* foodTests.swift in Sources */, 336 | ); 337 | runOnlyForDeploymentPostprocessing = 0; 338 | }; 339 | 8821893D25BEC29B00820A7E /* Sources */ = { 340 | isa = PBXSourcesBuildPhase; 341 | buildActionMask = 2147483647; 342 | files = ( 343 | 8821894625BEC29B00820A7E /* foodUITests.swift in Sources */, 344 | ); 345 | runOnlyForDeploymentPostprocessing = 0; 346 | }; 347 | /* End PBXSourcesBuildPhase section */ 348 | 349 | /* Begin PBXTargetDependency section */ 350 | 8821893825BEC29B00820A7E /* PBXTargetDependency */ = { 351 | isa = PBXTargetDependency; 352 | target = 8821892425BEC29900820A7E /* food */; 353 | targetProxy = 8821893725BEC29B00820A7E /* PBXContainerItemProxy */; 354 | }; 355 | 8821894325BEC29B00820A7E /* PBXTargetDependency */ = { 356 | isa = PBXTargetDependency; 357 | target = 8821892425BEC29900820A7E /* food */; 358 | targetProxy = 8821894225BEC29B00820A7E /* PBXContainerItemProxy */; 359 | }; 360 | /* End PBXTargetDependency section */ 361 | 362 | /* Begin XCBuildConfiguration section */ 363 | 8821894825BEC29B00820A7E /* Debug */ = { 364 | isa = XCBuildConfiguration; 365 | buildSettings = { 366 | ALWAYS_SEARCH_USER_PATHS = NO; 367 | CLANG_ANALYZER_NONNULL = YES; 368 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 369 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 370 | CLANG_CXX_LIBRARY = "libc++"; 371 | CLANG_ENABLE_MODULES = YES; 372 | CLANG_ENABLE_OBJC_ARC = YES; 373 | CLANG_ENABLE_OBJC_WEAK = YES; 374 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 375 | CLANG_WARN_BOOL_CONVERSION = YES; 376 | CLANG_WARN_COMMA = YES; 377 | CLANG_WARN_CONSTANT_CONVERSION = YES; 378 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 379 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 380 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 381 | CLANG_WARN_EMPTY_BODY = YES; 382 | CLANG_WARN_ENUM_CONVERSION = YES; 383 | CLANG_WARN_INFINITE_RECURSION = YES; 384 | CLANG_WARN_INT_CONVERSION = YES; 385 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 386 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 387 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 388 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 389 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 390 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 391 | CLANG_WARN_STRICT_PROTOTYPES = YES; 392 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 393 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 394 | CLANG_WARN_UNREACHABLE_CODE = YES; 395 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 396 | COPY_PHASE_STRIP = NO; 397 | DEBUG_INFORMATION_FORMAT = dwarf; 398 | ENABLE_STRICT_OBJC_MSGSEND = YES; 399 | ENABLE_TESTABILITY = YES; 400 | GCC_C_LANGUAGE_STANDARD = gnu11; 401 | GCC_DYNAMIC_NO_PIC = NO; 402 | GCC_NO_COMMON_BLOCKS = YES; 403 | GCC_OPTIMIZATION_LEVEL = 0; 404 | GCC_PREPROCESSOR_DEFINITIONS = ( 405 | "DEBUG=1", 406 | "$(inherited)", 407 | ); 408 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 409 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 410 | GCC_WARN_UNDECLARED_SELECTOR = YES; 411 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 412 | GCC_WARN_UNUSED_FUNCTION = YES; 413 | GCC_WARN_UNUSED_VARIABLE = YES; 414 | IPHONEOS_DEPLOYMENT_TARGET = 14.3; 415 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; 416 | MTL_FAST_MATH = YES; 417 | ONLY_ACTIVE_ARCH = YES; 418 | SDKROOT = iphoneos; 419 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 420 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 421 | }; 422 | name = Debug; 423 | }; 424 | 8821894925BEC29B00820A7E /* Release */ = { 425 | isa = XCBuildConfiguration; 426 | buildSettings = { 427 | ALWAYS_SEARCH_USER_PATHS = NO; 428 | CLANG_ANALYZER_NONNULL = YES; 429 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 430 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 431 | CLANG_CXX_LIBRARY = "libc++"; 432 | CLANG_ENABLE_MODULES = YES; 433 | CLANG_ENABLE_OBJC_ARC = YES; 434 | CLANG_ENABLE_OBJC_WEAK = YES; 435 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 436 | CLANG_WARN_BOOL_CONVERSION = YES; 437 | CLANG_WARN_COMMA = YES; 438 | CLANG_WARN_CONSTANT_CONVERSION = YES; 439 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 440 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 441 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 442 | CLANG_WARN_EMPTY_BODY = YES; 443 | CLANG_WARN_ENUM_CONVERSION = YES; 444 | CLANG_WARN_INFINITE_RECURSION = YES; 445 | CLANG_WARN_INT_CONVERSION = YES; 446 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 447 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 448 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 449 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 450 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 451 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 452 | CLANG_WARN_STRICT_PROTOTYPES = YES; 453 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 454 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 455 | CLANG_WARN_UNREACHABLE_CODE = YES; 456 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 457 | COPY_PHASE_STRIP = NO; 458 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 459 | ENABLE_NS_ASSERTIONS = NO; 460 | ENABLE_STRICT_OBJC_MSGSEND = YES; 461 | GCC_C_LANGUAGE_STANDARD = gnu11; 462 | GCC_NO_COMMON_BLOCKS = YES; 463 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 464 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 465 | GCC_WARN_UNDECLARED_SELECTOR = YES; 466 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 467 | GCC_WARN_UNUSED_FUNCTION = YES; 468 | GCC_WARN_UNUSED_VARIABLE = YES; 469 | IPHONEOS_DEPLOYMENT_TARGET = 14.3; 470 | MTL_ENABLE_DEBUG_INFO = NO; 471 | MTL_FAST_MATH = YES; 472 | SDKROOT = iphoneos; 473 | SWIFT_COMPILATION_MODE = wholemodule; 474 | SWIFT_OPTIMIZATION_LEVEL = "-O"; 475 | VALIDATE_PRODUCT = YES; 476 | }; 477 | name = Release; 478 | }; 479 | 8821894B25BEC29B00820A7E /* Debug */ = { 480 | isa = XCBuildConfiguration; 481 | buildSettings = { 482 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 483 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; 484 | CODE_SIGN_STYLE = Automatic; 485 | DEVELOPMENT_ASSET_PATHS = "\"food/Preview Content\""; 486 | ENABLE_PREVIEWS = YES; 487 | INFOPLIST_FILE = food/Info.plist; 488 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 489 | LD_RUNPATH_SEARCH_PATHS = ( 490 | "$(inherited)", 491 | "@executable_path/Frameworks", 492 | ); 493 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.food; 494 | PRODUCT_NAME = "$(TARGET_NAME)"; 495 | SWIFT_VERSION = 5.0; 496 | TARGETED_DEVICE_FAMILY = "1,2"; 497 | }; 498 | name = Debug; 499 | }; 500 | 8821894C25BEC29B00820A7E /* Release */ = { 501 | isa = XCBuildConfiguration; 502 | buildSettings = { 503 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 504 | ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; 505 | CODE_SIGN_STYLE = Automatic; 506 | DEVELOPMENT_ASSET_PATHS = "\"food/Preview Content\""; 507 | ENABLE_PREVIEWS = YES; 508 | INFOPLIST_FILE = food/Info.plist; 509 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 510 | LD_RUNPATH_SEARCH_PATHS = ( 511 | "$(inherited)", 512 | "@executable_path/Frameworks", 513 | ); 514 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.food; 515 | PRODUCT_NAME = "$(TARGET_NAME)"; 516 | SWIFT_VERSION = 5.0; 517 | TARGETED_DEVICE_FAMILY = "1,2"; 518 | }; 519 | name = Release; 520 | }; 521 | 8821894E25BEC29B00820A7E /* Debug */ = { 522 | isa = XCBuildConfiguration; 523 | buildSettings = { 524 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 525 | BUNDLE_LOADER = "$(TEST_HOST)"; 526 | CODE_SIGN_STYLE = Automatic; 527 | INFOPLIST_FILE = foodTests/Info.plist; 528 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 529 | LD_RUNPATH_SEARCH_PATHS = ( 530 | "$(inherited)", 531 | "@executable_path/Frameworks", 532 | "@loader_path/Frameworks", 533 | ); 534 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.foodTests; 535 | PRODUCT_NAME = "$(TARGET_NAME)"; 536 | SWIFT_VERSION = 5.0; 537 | TARGETED_DEVICE_FAMILY = "1,2"; 538 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/food.app/food"; 539 | }; 540 | name = Debug; 541 | }; 542 | 8821894F25BEC29B00820A7E /* Release */ = { 543 | isa = XCBuildConfiguration; 544 | buildSettings = { 545 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 546 | BUNDLE_LOADER = "$(TEST_HOST)"; 547 | CODE_SIGN_STYLE = Automatic; 548 | INFOPLIST_FILE = foodTests/Info.plist; 549 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 550 | LD_RUNPATH_SEARCH_PATHS = ( 551 | "$(inherited)", 552 | "@executable_path/Frameworks", 553 | "@loader_path/Frameworks", 554 | ); 555 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.foodTests; 556 | PRODUCT_NAME = "$(TARGET_NAME)"; 557 | SWIFT_VERSION = 5.0; 558 | TARGETED_DEVICE_FAMILY = "1,2"; 559 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/food.app/food"; 560 | }; 561 | name = Release; 562 | }; 563 | 8821895125BEC29B00820A7E /* Debug */ = { 564 | isa = XCBuildConfiguration; 565 | buildSettings = { 566 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 567 | CODE_SIGN_STYLE = Automatic; 568 | INFOPLIST_FILE = foodUITests/Info.plist; 569 | LD_RUNPATH_SEARCH_PATHS = ( 570 | "$(inherited)", 571 | "@executable_path/Frameworks", 572 | "@loader_path/Frameworks", 573 | ); 574 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.foodUITests; 575 | PRODUCT_NAME = "$(TARGET_NAME)"; 576 | SWIFT_VERSION = 5.0; 577 | TARGETED_DEVICE_FAMILY = "1,2"; 578 | TEST_TARGET_NAME = food; 579 | }; 580 | name = Debug; 581 | }; 582 | 8821895225BEC29B00820A7E /* Release */ = { 583 | isa = XCBuildConfiguration; 584 | buildSettings = { 585 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 586 | CODE_SIGN_STYLE = Automatic; 587 | INFOPLIST_FILE = foodUITests/Info.plist; 588 | LD_RUNPATH_SEARCH_PATHS = ( 589 | "$(inherited)", 590 | "@executable_path/Frameworks", 591 | "@loader_path/Frameworks", 592 | ); 593 | PRODUCT_BUNDLE_IDENTIFIER = TheSwiftWay.foodUITests; 594 | PRODUCT_NAME = "$(TARGET_NAME)"; 595 | SWIFT_VERSION = 5.0; 596 | TARGETED_DEVICE_FAMILY = "1,2"; 597 | TEST_TARGET_NAME = food; 598 | }; 599 | name = Release; 600 | }; 601 | /* End XCBuildConfiguration section */ 602 | 603 | /* Begin XCConfigurationList section */ 604 | 8821892025BEC29900820A7E /* Build configuration list for PBXProject "food" */ = { 605 | isa = XCConfigurationList; 606 | buildConfigurations = ( 607 | 8821894825BEC29B00820A7E /* Debug */, 608 | 8821894925BEC29B00820A7E /* Release */, 609 | ); 610 | defaultConfigurationIsVisible = 0; 611 | defaultConfigurationName = Release; 612 | }; 613 | 8821894A25BEC29B00820A7E /* Build configuration list for PBXNativeTarget "food" */ = { 614 | isa = XCConfigurationList; 615 | buildConfigurations = ( 616 | 8821894B25BEC29B00820A7E /* Debug */, 617 | 8821894C25BEC29B00820A7E /* Release */, 618 | ); 619 | defaultConfigurationIsVisible = 0; 620 | defaultConfigurationName = Release; 621 | }; 622 | 8821894D25BEC29B00820A7E /* Build configuration list for PBXNativeTarget "foodTests" */ = { 623 | isa = XCConfigurationList; 624 | buildConfigurations = ( 625 | 8821894E25BEC29B00820A7E /* Debug */, 626 | 8821894F25BEC29B00820A7E /* Release */, 627 | ); 628 | defaultConfigurationIsVisible = 0; 629 | defaultConfigurationName = Release; 630 | }; 631 | 8821895025BEC29B00820A7E /* Build configuration list for PBXNativeTarget "foodUITests" */ = { 632 | isa = XCConfigurationList; 633 | buildConfigurations = ( 634 | 8821895125BEC29B00820A7E /* Debug */, 635 | 8821895225BEC29B00820A7E /* Release */, 636 | ); 637 | defaultConfigurationIsVisible = 0; 638 | defaultConfigurationName = Release; 639 | }; 640 | /* End XCConfigurationList section */ 641 | }; 642 | rootObject = 8821891D25BEC29900820A7E /* Project object */; 643 | } 644 | -------------------------------------------------------------------------------- /food.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /food.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /food.xcodeproj/ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food.xcodeproj/ui.png -------------------------------------------------------------------------------- /food.xcodeproj/xcuserdata/abir.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | food.xcscheme_^#shared#^_ 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /food/Assets.xcassets/AccentColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "idiom" : "universal" 5 | } 6 | ], 7 | "info" : { 8 | "author" : "xcode", 9 | "version" : 1 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /food/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "scale" : "1x", 46 | "size" : "20x20" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "scale" : "2x", 51 | "size" : "20x20" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "scale" : "1x", 56 | "size" : "29x29" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "scale" : "2x", 61 | "size" : "29x29" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "scale" : "1x", 66 | "size" : "40x40" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "scale" : "2x", 71 | "size" : "40x40" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "scale" : "1x", 76 | "size" : "76x76" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "scale" : "2x", 81 | "size" : "76x76" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "scale" : "2x", 86 | "size" : "83.5x83.5" 87 | }, 88 | { 89 | "idiom" : "ios-marketing", 90 | "scale" : "1x", 91 | "size" : "1024x1024" 92 | } 93 | ], 94 | "info" : { 95 | "author" : "xcode", 96 | "version" : 1 97 | } 98 | } 99 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /food/Assets.xcassets/GrayColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "color" : { 5 | "color-space" : "srgb", 6 | "components" : { 7 | "alpha" : "1.000", 8 | "blue" : "0.776", 9 | "green" : "0.718", 10 | "red" : "0.698" 11 | } 12 | }, 13 | "idiom" : "universal" 14 | }, 15 | { 16 | "appearances" : [ 17 | { 18 | "appearance" : "luminosity", 19 | "value" : "dark" 20 | } 21 | ], 22 | "color" : { 23 | "color-space" : "srgb", 24 | "components" : { 25 | "alpha" : "1.000", 26 | "blue" : "0.776", 27 | "green" : "0.718", 28 | "red" : "0.698" 29 | } 30 | }, 31 | "idiom" : "universal" 32 | } 33 | ], 34 | "info" : { 35 | "author" : "xcode", 36 | "version" : 1 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/filter.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "filter.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/filter.imageset/filter.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/filter.imageset/filter.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/like.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "like.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/like.imageset/like.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/like.imageset/like.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/like_fill.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "like_fill.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/like_fill.imageset/like_fill.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/like_fill.imageset/like_fill.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/menu.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "menu.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/menu.imageset/menu.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/menu.imageset/menu.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/notifications.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "notifications.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/notifications.imageset/notifications.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/notifications.imageset/notifications.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/search.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "search.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/search.imageset/search.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/search.imageset/search.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/serving.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "serving.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/serving.imageset/serving.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/serving.imageset/serving.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/star.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "star.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/star.imageset/star.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/star.imageset/star.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/time.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "time.pdf", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Icons/time.imageset/time.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Icons/time.imageset/time.pdf -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/fresh_recipe_1.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "fresh_recipe_1.png", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/fresh_recipe_1.imageset/fresh_recipe_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Images/fresh_recipe_1.imageset/fresh_recipe_1.png -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/fresh_recipe_2.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "fresh_recipe_2.png", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/fresh_recipe_2.imageset/fresh_recipe_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Images/fresh_recipe_2.imageset/fresh_recipe_2.png -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_1.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "reco_1.png", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_1.imageset/reco_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Images/reco_1.imageset/reco_1.png -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_2.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "reco_2.png", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_2.imageset/reco_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Images/reco_2.imageset/reco_2.png -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_3.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "reco_3.png", 5 | "idiom" : "universal", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "author" : "xcode", 19 | "version" : 1 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /food/Assets.xcassets/Images/reco_3.imageset/reco_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/Assets.xcassets/Images/reco_3.imageset/reco_3.png -------------------------------------------------------------------------------- /food/Assets.xcassets/LightGrayColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "color" : { 5 | "color-space" : "srgb", 6 | "components" : { 7 | "alpha" : "1.000", 8 | "blue" : "0.988", 9 | "green" : "0.973", 10 | "red" : "0.969" 11 | } 12 | }, 13 | "idiom" : "universal" 14 | }, 15 | { 16 | "appearances" : [ 17 | { 18 | "appearance" : "luminosity", 19 | "value" : "dark" 20 | } 21 | ], 22 | "color" : { 23 | "color-space" : "srgb", 24 | "components" : { 25 | "alpha" : "1.000", 26 | "blue" : "0.988", 27 | "green" : "0.973", 28 | "red" : "0.969" 29 | } 30 | }, 31 | "idiom" : "universal" 32 | } 33 | ], 34 | "info" : { 35 | "author" : "xcode", 36 | "version" : 1 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /food/Assets.xcassets/PrimaryColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "color" : { 5 | "color-space" : "srgb", 6 | "components" : { 7 | "alpha" : "1.000", 8 | "blue" : "0.000", 9 | "green" : "0.353", 10 | "red" : "0.961" 11 | } 12 | }, 13 | "idiom" : "universal" 14 | }, 15 | { 16 | "appearances" : [ 17 | { 18 | "appearance" : "luminosity", 19 | "value" : "dark" 20 | } 21 | ], 22 | "color" : { 23 | "color-space" : "srgb", 24 | "components" : { 25 | "alpha" : "1.000", 26 | "blue" : "0.000", 27 | "green" : "0.353", 28 | "red" : "0.961" 29 | } 30 | }, 31 | "idiom" : "universal" 32 | } 33 | ], 34 | "info" : { 35 | "author" : "xcode", 36 | "version" : 1 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /food/Assets.xcassets/SecondaryColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "color" : { 5 | "color-space" : "srgb", 6 | "components" : { 7 | "alpha" : "1.000", 8 | "blue" : "0.682", 9 | "green" : "0.561", 10 | "red" : "0.071" 11 | } 12 | }, 13 | "idiom" : "universal" 14 | }, 15 | { 16 | "appearances" : [ 17 | { 18 | "appearance" : "luminosity", 19 | "value" : "dark" 20 | } 21 | ], 22 | "color" : { 23 | "color-space" : "srgb", 24 | "components" : { 25 | "alpha" : "1.000", 26 | "blue" : "0.682", 27 | "green" : "0.561", 28 | "red" : "0.071" 29 | } 30 | }, 31 | "idiom" : "universal" 32 | } 33 | ], 34 | "info" : { 35 | "author" : "xcode", 36 | "version" : 1 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /food/Assets.xcassets/TextColor.colorset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "colors" : [ 3 | { 4 | "color" : { 5 | "color-space" : "srgb", 6 | "components" : { 7 | "alpha" : "1.000", 8 | "blue" : "0.169", 9 | "green" : "0.133", 10 | "red" : "0.122" 11 | } 12 | }, 13 | "idiom" : "universal" 14 | }, 15 | { 16 | "appearances" : [ 17 | { 18 | "appearance" : "luminosity", 19 | "value" : "dark" 20 | } 21 | ], 22 | "color" : { 23 | "color-space" : "srgb", 24 | "components" : { 25 | "alpha" : "1.000", 26 | "blue" : "0.169", 27 | "green" : "0.133", 28 | "red" : "0.122" 29 | } 30 | }, 31 | "idiom" : "universal" 32 | } 33 | ], 34 | "info" : { 35 | "author" : "xcode", 36 | "version" : 1 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /food/ContentView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ContentView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct ContentView: View { 11 | 12 | 13 | var body: some View { 14 | VStack { 15 | HomeView() 16 | } 17 | } 18 | } 19 | 20 | struct ContentView_Previews: PreviewProvider { 21 | static var previews: some View { 22 | ContentView() 23 | } 24 | } 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /food/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | UIAppFonts 6 | 7 | Hellix-Medium.ttf 8 | Hellix-Bold.ttf 9 | Hellix-Regular.ttf 10 | Hellix-SemiBold.ttf 11 | Hellix-Thin.ttf 12 | 13 | CFBundleDevelopmentRegion 14 | $(DEVELOPMENT_LANGUAGE) 15 | CFBundleExecutable 16 | $(EXECUTABLE_NAME) 17 | CFBundleIdentifier 18 | $(PRODUCT_BUNDLE_IDENTIFIER) 19 | CFBundleInfoDictionaryVersion 20 | 6.0 21 | CFBundleName 22 | $(PRODUCT_NAME) 23 | CFBundlePackageType 24 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 25 | CFBundleShortVersionString 26 | 1.0 27 | CFBundleVersion 28 | 1 29 | LSRequiresIPhoneOS 30 | 31 | UIApplicationSceneManifest 32 | 33 | UIApplicationSupportsMultipleScenes 34 | 35 | 36 | UIApplicationSupportsIndirectInputEvents 37 | 38 | UILaunchScreen 39 | 40 | UIRequiredDeviceCapabilities 41 | 42 | armv7 43 | 44 | UISupportedInterfaceOrientations 45 | 46 | UIInterfaceOrientationPortrait 47 | UIInterfaceOrientationLandscapeLeft 48 | UIInterfaceOrientationLandscapeRight 49 | 50 | UISupportedInterfaceOrientations~ipad 51 | 52 | UIInterfaceOrientationPortrait 53 | UIInterfaceOrientationPortraitUpsideDown 54 | UIInterfaceOrientationLandscapeLeft 55 | UIInterfaceOrientationLandscapeRight 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /food/Preview Content/Preview Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /food/Views/FreshRecipesView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // FreshRecipesView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct FreshRecipesView: View { 11 | var body: some View { 12 | VStack (alignment: .leading, spacing: 16) { 13 | SectionTitleView(title: "Today's Fresh Recipes") 14 | 15 | ScrollView (.horizontal, showsIndicators: false) { 16 | HStack (spacing: 16) { 17 | RecipeCard(image: #imageLiteral(resourceName: "fresh_recipe_1")) 18 | RecipeCard(image: #imageLiteral(resourceName: "fresh_recipe_2")) 19 | } 20 | } 21 | } 22 | } 23 | } 24 | 25 | struct RecipeCard: View { 26 | let image: UIImage 27 | var body: some View { 28 | ZStack { 29 | VStack (alignment: .leading, spacing: 8) { 30 | Image(uiImage: #imageLiteral(resourceName: "like")) 31 | .padding(.bottom, 60) 32 | Text("Breakfast") 33 | .font(.caption) 34 | .foregroundColor(Color(#colorLiteral(red: 0.07058823529, green: 0.5607843137, blue: 0.6823529412, alpha: 1))) 35 | Text("French Toast with Berries") 36 | .fontWeight(.medium) 37 | .lineLimit(nil) 38 | HStack (spacing: 2) { 39 | ForEach(0 ..< 5) { item in 40 | Image(uiImage: #imageLiteral(resourceName: "star")) 41 | .renderingMode(.template) 42 | .foregroundColor(Color("PrimaryColor")) 43 | } 44 | } 45 | Text("120 Calories") 46 | .font(.caption) 47 | .foregroundColor(Color("PrimaryColor")) 48 | 49 | HStack { 50 | Image(uiImage: #imageLiteral(resourceName: "time")) 51 | Text("10 mins") 52 | .font(.caption2) 53 | .foregroundColor(Color("GrayColor")) 54 | Spacer() 55 | 56 | Image(uiImage: #imageLiteral(resourceName: "serving")) 57 | Text("1 Serving") 58 | .font(.caption2) 59 | .foregroundColor(Color("GrayColor")) 60 | } 61 | 62 | } 63 | .frame(width: 147) 64 | .padding() 65 | .background(Color("LightGrayColor")) 66 | .cornerRadius(20.0) 67 | 68 | // Image 69 | Image(uiImage: image) 70 | .offset(x: 45, y: -60) 71 | 72 | } 73 | .padding(.trailing, 25) 74 | } 75 | } 76 | 77 | 78 | -------------------------------------------------------------------------------- /food/Views/HomeNavBarView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // HomeNavBarView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct HomeNavBarView: View { 11 | var body: some View { 12 | HStack { 13 | Image(uiImage: #imageLiteral(resourceName: "menu")) 14 | .onTapGesture { 15 | 16 | } 17 | 18 | Spacer() 19 | 20 | Image(uiImage: #imageLiteral(resourceName: "notifications")) 21 | .onTapGesture { 22 | 23 | } 24 | 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /food/Views/HomeView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // HomeView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct HomeView: View { 11 | @State private var search: String = "" 12 | var body: some View { 13 | ScrollView (showsIndicators: false) { 14 | VStack (alignment: .leading, spacing: 16){ 15 | HomeNavBarView() 16 | 17 | Text("Bonjour, Emma") 18 | .font(.caption) 19 | .fontWeight(.medium) 20 | .foregroundColor(Color("GrayColor")) 21 | 22 | Text("What would you like to cook today?") 23 | .font(.title) 24 | .fontWeight(.bold) 25 | 26 | SearchAndFilterView(search: $search) 27 | 28 | FreshRecipesView() 29 | 30 | SectionTitleView(title: "Recommended") 31 | 32 | 33 | RecommendedRecipeCardView(image: #imageLiteral(resourceName: "reco_1"), title: "Blueberry Muffins") 34 | RecommendedRecipeCardView(image: #imageLiteral(resourceName: "reco_2"), title: "Glazed Salmon") 35 | RecommendedRecipeCardView(image: #imageLiteral(resourceName: "reco_3"), title: "Asian Glazed Chicken Thighs") 36 | 37 | } 38 | .padding() 39 | } 40 | } 41 | } 42 | 43 | 44 | struct HomeView_Previews: PreviewProvider { 45 | static var previews: some View { 46 | HomeView() 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /food/Views/RecommendedRecipeCardView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // RecommendedRecipeCardView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct RecommendedRecipeCardView: View { 11 | let image: UIImage 12 | let title: String 13 | 14 | 15 | var body: some View { 16 | HStack { 17 | Image(uiImage: image) 18 | .aspectRatio(1, contentMode: .fill) 19 | .padding(.trailing, 4) 20 | 21 | VStack (alignment: .leading, spacing: 4) { 22 | HStack { 23 | Text("Breakfast") 24 | .font(.caption2) 25 | .foregroundColor(Color(#colorLiteral(red: 0, green: 0.6272217631, blue: 0.7377799153, alpha: 1))) 26 | Spacer() 27 | 28 | Image(uiImage: #imageLiteral(resourceName: "like")) 29 | } 30 | Text(title) 31 | .fontWeight(.medium) 32 | 33 | HStack (spacing: 2) { 34 | ForEach(0 ..< 5) { item in 35 | Image(uiImage: #imageLiteral(resourceName: "star")) 36 | .renderingMode(.template) 37 | .foregroundColor(Color("PrimaryColor")) 38 | } 39 | 40 | Text("120 Calories") 41 | .font(.caption) 42 | .foregroundColor(Color("PrimaryColor")) 43 | .padding(.leading) 44 | } 45 | 46 | HStack { 47 | Image(uiImage: #imageLiteral(resourceName: "time")) 48 | Text("10 mins") 49 | .font(.caption2) 50 | .foregroundColor(Color("GrayColor")) 51 | 52 | 53 | Image(uiImage: #imageLiteral(resourceName: "serving")) 54 | .padding(.leading) 55 | Text("1 Serving") 56 | .font(.caption2) 57 | .foregroundColor(Color("GrayColor")) 58 | 59 | } 60 | } 61 | .frame(maxWidth: .infinity) 62 | 63 | } 64 | .padding() 65 | .frame(maxWidth: .infinity) 66 | .background(Color("LightGrayColor")) 67 | .cornerRadius(18.0) 68 | } 69 | } 70 | -------------------------------------------------------------------------------- /food/Views/SearchAndFilterView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SearchAndFilterView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct SearchAndFilterView: View { 11 | @Binding var search: String 12 | 13 | var body: some View { 14 | HStack (spacing: 16){ 15 | // Search 16 | HStack { 17 | Image(uiImage: #imageLiteral(resourceName: "search")) 18 | TextField("Search for recipes", text: $search) 19 | 20 | } 21 | .padding() 22 | .background(Color("LightGrayColor")) 23 | .cornerRadius(8) 24 | 25 | Image(uiImage: #imageLiteral(resourceName: "filter")) 26 | .padding() 27 | .background(Color("LightGrayColor")) 28 | .cornerRadius(8.0) 29 | .onTapGesture { 30 | 31 | } 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /food/Views/SectionTitleView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // SectionTitleView.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | struct SectionTitleView: View { 11 | let title: String 12 | 13 | var body: some View { 14 | HStack { 15 | Text(title) 16 | .font(.title2) 17 | .fontWeight(.bold) 18 | 19 | Spacer() 20 | 21 | Text("See All") 22 | .foregroundColor(Color("PrimaryColor")) 23 | .onTapGesture { 24 | 25 | } 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /food/fonts/Hellix-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/fonts/Hellix-Bold.ttf -------------------------------------------------------------------------------- /food/fonts/Hellix-Medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/fonts/Hellix-Medium.ttf -------------------------------------------------------------------------------- /food/fonts/Hellix-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/fonts/Hellix-Regular.ttf -------------------------------------------------------------------------------- /food/fonts/Hellix-SemiBold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/fonts/Hellix-SemiBold.ttf -------------------------------------------------------------------------------- /food/fonts/Hellix-Thin.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/abuanwar072/Food-App-UI-by-using-SwiftUI/fe61f644a314516a548573f7a793d76618e5d322/food/fonts/Hellix-Thin.ttf -------------------------------------------------------------------------------- /food/foodApp.swift: -------------------------------------------------------------------------------- 1 | // 2 | // foodApp.swift 3 | // food 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import SwiftUI 9 | 10 | @main 11 | struct foodApp: App { 12 | var body: some Scene { 13 | WindowGroup { 14 | ContentView() 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /foodTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /foodTests/foodTests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // foodTests.swift 3 | // foodTests 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import XCTest 9 | @testable import food 10 | 11 | class foodTests: XCTestCase { 12 | 13 | override func setUpWithError() throws { 14 | // Put setup code here. This method is called before the invocation of each test method in the class. 15 | } 16 | 17 | override func tearDownWithError() throws { 18 | // Put teardown code here. This method is called after the invocation of each test method in the class. 19 | } 20 | 21 | func testExample() throws { 22 | // This is an example of a functional test case. 23 | // Use XCTAssert and related functions to verify your tests produce the correct results. 24 | } 25 | 26 | func testPerformanceExample() throws { 27 | // This is an example of a performance test case. 28 | self.measure { 29 | // Put the code you want to measure the time of here. 30 | } 31 | } 32 | 33 | } 34 | -------------------------------------------------------------------------------- /foodUITests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /foodUITests/foodUITests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // foodUITests.swift 3 | // foodUITests 4 | // 5 | // Created by Abu Anwar MD Abdullah on 25/1/21. 6 | // 7 | 8 | import XCTest 9 | 10 | class foodUITests: XCTestCase { 11 | 12 | override func setUpWithError() throws { 13 | // Put setup code here. This method is called before the invocation of each test method in the class. 14 | 15 | // In UI tests it is usually best to stop immediately when a failure occurs. 16 | continueAfterFailure = false 17 | 18 | // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. 19 | } 20 | 21 | override func tearDownWithError() throws { 22 | // Put teardown code here. This method is called after the invocation of each test method in the class. 23 | } 24 | 25 | func testExample() throws { 26 | // UI tests must launch the application that they test. 27 | let app = XCUIApplication() 28 | app.launch() 29 | 30 | // Use recording to get started writing UI tests. 31 | // Use XCTAssert and related functions to verify your tests produce the correct results. 32 | } 33 | 34 | func testLaunchPerformance() throws { 35 | if #available(macOS 10.15, iOS 13.0, tvOS 13.0, *) { 36 | // This measures how long it takes to launch your application. 37 | measure(metrics: [XCTApplicationLaunchMetric()]) { 38 | XCUIApplication().launch() 39 | } 40 | } 41 | } 42 | } 43 | --------------------------------------------------------------------------------