import type { IngredientGroup } from "./ingredientGroup"
import type { Servings } from "./servings"

/**
 * Represents a recipe object in the application.
 */
/*
 * @todo ingredient groups! There may be serveral ingredient lists, each with a title.
 * e.g. for the dough, for the filling, for the icing,...
 * - add type ingredient group with an optional title and a list of ingredients
 * - adapt RecipeDetailView
 * - add an IngredientGroupListEditor for handling IngredientGroups
*/
export interface Recipe {
  /** Unique identifier for the recipe */
  id: string

  /** Title of the recipe */
  title: string

  /** List of ingredients groups containing the ingredients of the recipe */
  ingredientGroupList: IngredientGroup[]

  /** Preparation instructions */
  instructions: string

  /** Number of servings, e.g., for 4 person, 12 cupcakes, 2 glasses */
  servings: Servings

  /** Unit for the quantity */

  /** Optional image URL for the recipe */
  imageUrl?: string
}