From 0a814fa89622cd1a1b909578107cdd09dd215bfd Mon Sep 17 00:00:00 2001 From: vabene1111 Date: Sat, 16 Dec 2023 08:18:05 +0100 Subject: [PATCH] dont hide ingredients in edit when hiding them in view --- vue/src/apps/RecipeEditView/RecipeEditView.vue | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/vue/src/apps/RecipeEditView/RecipeEditView.vue b/vue/src/apps/RecipeEditView/RecipeEditView.vue index 832019abbf..2649c0371c 100644 --- a/vue/src/apps/RecipeEditView/RecipeEditView.vue +++ b/vue/src/apps/RecipeEditView/RecipeEditView.vue @@ -937,10 +937,7 @@ export default { // set default visibility style for each component of the step this.recipe.steps.forEach((s) => { this.$set(s, "time_visible", s.time !== 0) - // ingredients_visible determines whether or not the ingredients UI is shown in the edit view - // show_ingredients_table determine whether the ingredients table is shown in the read view - // these are seperate as one might want to add ingredients but not want the step-level view - this.$set(s, "ingredients_visible", s.show_ingredients_table && (s.ingredients.length > 0 || this.recipe.steps.length === 1)) + this.$set(s, "ingredients_visible", (s.ingredients.length > 0 || this.recipe.steps.length === 1)) this.$set(s, "instruction_visible", s.instruction !== "" || this.recipe.steps.length === 1) this.$set(s, "step_recipe_visible", s.step_recipe !== null) this.$set(s, "file_visible", s.file !== null)