diff --git a/src/components/Detail/StepIngredientSideView.astro b/src/components/Detail/StepIngredientSideView.astro new file mode 100644 index 0000000..5b6c7dd --- /dev/null +++ b/src/components/Detail/StepIngredientSideView.astro @@ -0,0 +1,17 @@ +--- +import client from "@/data/pocketbase"; + +const { ingredients, class: className } = Astro.props; + +const ings = await Promise.all( + ingredients.map(async i => await client.collection("ingredients").getOne(i)) +) +--- + +
• {i.quantity} {i.unit || " "} {i.name}
+Steps
{ steps.map(s => ( -Step {s.index + 1}
-{s.instruction}
+ +{s.instruction}
+ {s.ingredients && s.ingredients.length > 0 && ( +