diff --git a/index.html b/index.html index e7406f0..38f1b9c 100644 --- a/index.html +++ b/index.html @@ -1,7 +1,6 @@ - isa9 – EIS SoSe 25 @@ -13,6 +12,7 @@

cyan.

+

Creative Studio.

diff --git a/js/script.js b/js/script.js index 896835d..9e79bcc 100644 --- a/js/script.js +++ b/js/script.js @@ -42,4 +42,18 @@ document.addEventListener("DOMContentLoaded", () => { const isDark = document.body.classList.contains("dark"); localStorage.setItem("darkMode", isDark); }); -}); \ No newline at end of file +}); + +// Begruessung nach Tageszeit +const stunde = new Date().getHours(); +let text; + +if (stunde < 10) { + text = "Guten Morgen!"; +} else if (stunde < 18) { + text = "Hallo, schön dass du da bist!"; +} else { + text = "Guten Abend!"; +} + +document.getElementById("begruessung").textContent = text; \ No newline at end of file