From 02b6ecc225c5271329cd240f8402e2beeb353c28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc?= <1536036+zoic21@users.noreply.github.com> Date: Tue, 9 Apr 2024 13:17:46 +0200 Subject: [PATCH] Update utils.js --- desktop/common/js/utils.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/desktop/common/js/utils.js b/desktop/common/js/utils.js index 3f0c32269e..9123314f4d 100644 --- a/desktop/common/js/utils.js +++ b/desktop/common/js/utils.js @@ -23,7 +23,7 @@ var jeedomUtils = { } jeedomUtils.tileWidthStep = (parseInt(jeedom.theme['widget::step::width']) > 1 ? parseInt(jeedom.theme['widget::step::width']) : 1) + parseInt(jeedom.theme['widget::margin']) // with margin jeedomUtils.tileHeightStep = (parseInt(jeedom.theme['widget::step::height']) > 1 ? parseInt(jeedom.theme['widget::step::height']) : 1) + parseInt(jeedom.theme['widget::margin']) // with margin -jeedomUtils.tileHeightSteps = Array.apply(null, { length: 50 }).map(function(value, index) { return (index + 1) * jeedomUtils.tileHeightStep }) +jeedomUtils.tileHeightSteps = Array.apply(null, { length: 500 }).map(function(value, index) { return (index + 1) * jeedomUtils.tileHeightStep }) /*Hijack jQuery ready function, still used in plugins @@ -1478,7 +1478,7 @@ jeedomUtils.positionEqLogic = function(_id, _preResize, _scenario) { var cols = Math.floor(containerWidth / jeedomUtils.tileWidthStep) var tileWidthAdd = containerWidth - (cols * jeedomUtils.tileWidthStep) var widthStep = jeedomUtils.tileWidthStep + (tileWidthAdd / cols) - var widthSteps = Array.apply(null, { length: 50 }).map(function(value, index) { return (index + 1) * widthStep }) + var widthSteps = Array.apply(null, { length: 500 }).map(function(value, index) { return (index + 1) * widthStep }) if (_id != undefined) { var tile = (_scenario) ? document.querySelector('.scenario-widget[data-scenario_id="' + _id + '"]') : document.querySelector('.eqLogic-widget[data-eqlogic_id="' + _id + '"]')