diff --git a/frontend/src/lib/components/header/desktop.svelte b/frontend/src/lib/components/header/desktop.svelte index d0be73f..d9ec78e 100644 --- a/frontend/src/lib/components/header/desktop.svelte +++ b/frontend/src/lib/components/header/desktop.svelte @@ -47,13 +47,13 @@ } textElement = document.getElementById("lowerpc") - console.log(textElement, "textel") + containerWidth = container.offsetWidth textWidth = textElement.offsetWidth characterCount = textElement.textContent.length - 1 spaceNeeded = containerWidth - textWidth - console.log(characterCount, spaceNeeded, containerWidth) + if (characterCount > 0 && spaceNeeded > 0) { const letterSpacing = spaceNeeded / characterCount textElement.style.letterSpacing = `${letterSpacing}px` @@ -101,8 +101,8 @@ logo
-

all kids

-

SO GÜNSTIG WIE NACHHALTIG

+
all kids
+
SO GÜNSTIG WIE NACHHALTIG
-

all kids

-

SO GÜNSTIG WIE NACHHALTIG

+
all kids
+
SO GÜNSTIG WIE NACHHALTIG