From a931aa59a3b09cf0a0eb4ac861ca02f333ef53c8 Mon Sep 17 00:00:00 2001 From: patriceac <48073125+patriceac@users.noreply.github.com> Date: Tue, 7 Feb 2023 18:02:42 -0800 Subject: [PATCH] Fix the behavior of the use as input button Clicking the button toggles the task container behind it. --- ui/media/js/main.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ui/media/js/main.js b/ui/media/js/main.js index b0842620..0bbdb13b 100644 --- a/ui/media/js/main.js +++ b/ui/media/js/main.js @@ -774,7 +774,10 @@ function createInitImageHover(taskEntry) { img.src = taskEntry.querySelector('div.task-initimg > img').src $tooltip.append(img) $tooltip.append(`
`) - $tooltip.find('button').on('click', (e) => { onUseAsInputClick(null,img) } ) + $tooltip.find('button').on('click', (e) => { + e.stopPropagation() + onUseAsInputClick(null,img) + }) } let startX, startY;