iobroker.mywebui 1.37.99 → 1.38.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/io-package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "mywebui",
4
- "version": "1.37.99",
4
+ "version": "1.38.00",
5
5
  "titleLang": {
6
6
  "en": "mywebui",
7
7
  "de": "mywebui",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.mywebui",
3
- "version": "1.37.99",
3
+ "version": "1.38.00",
4
4
  "description": "ioBroker mywebui - Custom edited mywebui by gokturk413",
5
5
  "type": "module",
6
6
  "main": "dist/backend/main.js",
@@ -1247,9 +1247,11 @@ export class IobrokerWebuiAppShell extends BaseCustomWebComponentConstructorAppe
1247
1247
 
1248
1248
  const condSel = sel([['equal','='],['not_equal','≠'],['less_than','<'],['greater_than','>'],['exists','exists']], cfg.condition || 'equal');
1249
1249
  const condValInp = inp(cfg.conditionValue ?? 'true');
1250
- const glowColorInp = inp(cfg.glowColor || 'yellow', 'color');
1251
- const glowSizeInp = inp(cfg.glowSize || 10, 'number');
1252
- const blurInp = inp(cfg.blurAmount || 5, 'number');
1250
+ const glowColorInp = inp(cfg.glowColor || 'yellow', 'color');
1251
+ const glowSizeInp = inp(cfg.glowSize || 10, 'number');
1252
+ const blurInp = inp(cfg.blurAmount || 5, 'number');
1253
+ const pulseScaleInp = inp(cfg.scale ?? 2.5, 'number');
1254
+ const pulseOpacityInp= inp(cfg.opacityFrom ?? 1, 'number');
1253
1255
 
1254
1256
  body.appendChild(field('Type', 'type', typeSel));
1255
1257
  body.appendChild(field('Trigger', null, triggerSel));
@@ -1290,6 +1292,14 @@ export class IobrokerWebuiAppShell extends BaseCustomWebComponentConstructorAppe
1290
1292
  body.appendChild(blurSection);
1291
1293
  typeSel.addEventListener('change', () => { blurSection.style.display = typeSel.value === 'blur' ? '' : 'none'; });
1292
1294
 
1295
+ // Pulse Ring section
1296
+ const pulseRingSection = document.createElement('div');
1297
+ pulseRingSection.style.display = cfg.type === 'pulseRing' ? '' : 'none';
1298
+ pulseRingSection.appendChild(field('Scale', 'scale', pulseScaleInp));
1299
+ pulseRingSection.appendChild(field('Opacity From', 'opacityFrom', pulseOpacityInp));
1300
+ body.appendChild(pulseRingSection);
1301
+ typeSel.addEventListener('change', () => { pulseRingSection.style.display = typeSel.value === 'pulseRing' ? '' : 'none'; });
1302
+
1293
1303
  // _collect: read current UI values back into a plain object
1294
1304
  cfg._collect = () => {
1295
1305
  const out = {};
@@ -1302,6 +1312,7 @@ export class IobrokerWebuiAppShell extends BaseCustomWebComponentConstructorAppe
1302
1312
  if (triggerSel.value === 'oid') { out.condition = condSel.value; out.conditionValue = condValInp.value; }
1303
1313
  if (typeSel.value === 'glow') { out.glowColor = glowColorInp.value; out.glowSize = parseInt(glowSizeInp.value) || 10; }
1304
1314
  if (typeSel.value === 'blur') out.blurAmount = parseInt(blurInp.value) || 5;
1315
+ if (typeSel.value === 'pulseRing') { out.scale = parseFloat(pulseScaleInp.value) || 2.5; out.opacityFrom = parseFloat(pulseOpacityInp.value) ?? 1; }
1305
1316
  for (const [k, v] of Object.entries(cfg)) { if (k.endsWith('_bind') && v) out[k] = v; }
1306
1317
  return out;
1307
1318
  };
@@ -656,9 +656,11 @@ async function _applyEffect(el, cfg) {
656
656
  case 'pulseRing': {
657
657
  const scale = parseFloat(cfg.scale) || 2.5;
658
658
  const ringEase = cfg.ease || 'power1.out';
659
+ const isLoadTrigger = !cfg.trigger || cfg.trigger === 'load';
660
+ const pulseRepeat = repeat !== 0 ? repeat : (isLoadTrigger ? -1 : 0);
659
661
  gsap.fromTo(el,
660
662
  { scale: 0, opacity: cfg.opacityFrom != null ? parseFloat(cfg.opacityFrom) : 1 },
661
- { scale, opacity: 0, duration: dur, ease: ringEase, repeat: repeat !== 0 ? repeat : -1, delay, transformOrigin: '50% 50%' }
663
+ { scale, opacity: 0, duration: dur, ease: ringEase, repeat: pulseRepeat, delay, transformOrigin: '50% 50%' }
662
664
  ); break;
663
665
  }
664
666
  }