From 4125429d58d8e86b016fef1e2ffd1e1cf0d54d41 Mon Sep 17 00:00:00 2001 From: Bart van Andel Date: Sun, 6 Apr 2025 01:29:52 +0200 Subject: [PATCH] fix: ensure jquery tooltip is displayed correctly Move jquery tooltip logic to the buildRecipeOperation function, so it is called regardless of whether the recipe is loaded from the url (which already worked correctly) or by dropping ingredients (which wasn't working before) --- src/web/waiters/RecipeWaiter.mjs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/web/waiters/RecipeWaiter.mjs b/src/web/waiters/RecipeWaiter.mjs index 93ca1182..4272ef3b 100755 --- a/src/web/waiters/RecipeWaiter.mjs +++ b/src/web/waiters/RecipeWaiter.mjs @@ -417,6 +417,8 @@ class RecipeWaiter { el.classList.add("flow-control-op"); } + $(el).find("[data-toggle='tooltip']").tooltip(); + // Disable auto-bake if this is a manual op if (op.manualBake && this.app.autoBake_) { this.manager.controls.setAutoBake(false); @@ -442,8 +444,6 @@ class RecipeWaiter { this.buildRecipeOperation(item); document.getElementById("rec-list").appendChild(item); - $(item).find("[data-toggle='tooltip']").tooltip(); - item.dispatchEvent(this.manager.operationadd); return item; }