fix(planner): exclude current recipe from swap suggestions

Adds excludeRecipeId prop to SwapSuggestionList so the meal being
replaced is not offered as a swap candidate.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit was merged in pull request #45.
This commit is contained in:
2026-04-09 10:38:30 +02:00
parent b4fa3ca23e
commit f0bbb3b009
3 changed files with 24 additions and 2 deletions

View File

@@ -309,6 +309,7 @@
replacingMeta={replacingMeta || undefined}
recipes={sortedRecipes}
{currentWeekRecipeIds}
excludeRecipeId={selectedSlot.recipe?.id}
isLoading={swapLoading}
onpick={handleSwapPick}
oncancel={() => (swapSheetOpen = false)}
@@ -549,6 +550,7 @@
replacingMeta={replacingMeta || undefined}
recipes={sortedRecipes}
{currentWeekRecipeIds}
excludeRecipeId={pickerSlot.recipe.id}
onpick={handleRecipePick}
/>
</div>