From 80cdf0384b1863194f1e46a0080c4c64d7abd183 Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Mon, 26 May 2025 06:58:35 +0200 Subject: [PATCH] Add conditional check for cat glow element in animeCat.js --- animeCat.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/animeCat.js b/animeCat.js index 6d36e03..2643e00 100644 --- a/animeCat.js +++ b/animeCat.js @@ -105,6 +105,11 @@ window.AnimeCat = class AnimeCat { this.bubble.appendChild(this.bubblePointer); // --- Zusammenbauen --- + if (!this.wrapper.querySelector('#cat-glow')) { + this.glow = document.createElement('div'); + this.glow.id = 'cat-glow'; + this.wrapper.insertBefore(this.glow, this.img); // vor das Bild +} this.wrapper.appendChild(this.img); this.wrapper.appendChild(this.bubble); this.container.appendChild(this.wrapper);