Skip to content

Dynamic Meals #5

@AndrewFesenko

Description

@AndrewFesenko

Title

Dynamic meal servings with automatic ingredient scaling


Description

Currently, meals are stored with fixed ingredient quantities. For Sprint 2, we should support dynamic serving sizes so users can adjust how many servings they want and automatically update ingredient amounts.

Example:

If a recipe is stored as:

  • 1 cup rice
  • 2 chicken breasts
  • 1 tbsp olive oil

Then selecting:

  • 1 serving → shows original amounts
  • 2 servings → doubles all ingredients
  • 5 servings → multiplies all ingredients by 5

This would make meal planning more flexible and allow users to generate accurate grocery lists based on how many portions they actually want.


Proposed functionality

  • Store a defaultServings field for each recipe
  • Allow users to adjust number of servings dynamically
  • Automatically scale ingredient quantities based on servings
  • Update pantry usage estimates accordingly
  • Support fractional scaling (example: 1.5 servings)

Acceptance criteria

  • Recipes include a defaultServings field
  • Ingredient quantities scale dynamically when servings change
  • UI updates ingredient amounts immediately after adjustment
  • Scaling works for all numeric ingredient values
  • Pantry matching logic uses updated quantities

Future extensions (optional)

  • Save preferred serving size per user
  • Adjust nutrition estimates if added later
  • Auto-scale grocery list generation
  • Suggest batch cooking quantities

Priority

Sprint 2 feature

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions