-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added recipe detail view, some ui adjustments
- Loading branch information
1 parent
0261f7a
commit 7a751db
Showing
8 changed files
with
89 additions
and
25 deletions.
There are no files selected for viewing
Binary file modified
BIN
+13.9 KB
(110%)
....xcodeproj/project.xcworkspace/xcuserdata/matt.xcuserdatad/UserInterfaceState.xcuserstate
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"images" : [ | ||
{ | ||
"filename" : "food.jpg", | ||
"idiom" : "universal", | ||
"scale" : "1x" | ||
}, | ||
{ | ||
"idiom" : "universal", | ||
"scale" : "2x" | ||
}, | ||
{ | ||
"idiom" : "universal", | ||
"scale" : "3x" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// | ||
// RecipeDetail.swift | ||
// SwiftFood | ||
// | ||
// Created by Matthew Caballero on 12/11/24. | ||
// | ||
|
||
import SwiftUI | ||
|
||
struct RecipeDetail: View { | ||
var recipe: Recipe | ||
|
||
var body: some View { | ||
ScrollView { | ||
Image("food") | ||
.resizable() | ||
.scaledToFit() | ||
.frame(width: 250) | ||
VStack { | ||
Text(recipe.title) | ||
.font(.largeTitle) | ||
.padding() | ||
Text("Time required: \(String(format: "%.1f", recipe.time_required)) hours") | ||
Text("Serving count: \(recipe.servings_amount) servings") | ||
|
||
Text("Instructions:") | ||
.font(.title) | ||
.padding() | ||
Text(recipe.instructions) | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters