From 3a5bcdf8b9a141f7e629ac3a7174f20af3aac5a1 Mon Sep 17 00:00:00 2001 From: pythongosssss <125205205+pythongosssss@users.noreply.github.com> Date: Thu, 30 Mar 2023 20:15:12 +0100 Subject: [PATCH] Formatting --- web/scripts/ui.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/web/scripts/ui.js b/web/scripts/ui.js index 8c7f096d..194d8e2d 100644 --- a/web/scripts/ui.js +++ b/web/scripts/ui.js @@ -57,11 +57,11 @@ function dragElement(dragEl, settings) { function ensureInBounds() { if (dragEl.classList.contains("comfy-menu-manual-pos")) { - newPosX = Math.min(document.body.clientWidth - dragEl.clientWidth, Math.max(0, dragEl.offsetLeft)); - newPosY = Math.min(document.body.clientHeight - dragEl.clientHeight, Math.max(0, dragEl.offsetTop)); + newPosX = Math.min(document.body.clientWidth - dragEl.clientWidth, Math.max(0, dragEl.offsetLeft)); + newPosY = Math.min(document.body.clientHeight - dragEl.clientHeight, Math.max(0, dragEl.offsetTop)); - positionElement(); - } + positionElement(); + } } function positionElement() {