]> danix's work - danix.xyz-2.git/commitdiff
fix: add type="button" to all buttons to prevent form submission behavior
authorDanilo M. <redacted>
Fri, 17 Apr 2026 09:36:25 +0000 (11:36 +0200)
committerDanilo M. <redacted>
Fri, 17 Apr 2026 09:36:25 +0000 (11:36 +0200)
themes/danix-xyz-hacker/layouts/404.html

index 16cbb2288b99aca2316def2619229ee9c1075f27..2bf212dcefdaf2c68fe50d084725323c2683b8f7 100644 (file)
@@ -91,6 +91,7 @@ window.articlesData = [
     <!-- Easter Egg Trigger -->
     <div class="mt-12 pt-8 border-t border-border">
       <button
+        type="button"
         @click="toggleEasterEgg()"
         class="text-sm text-text-dim hover:text-accent transition-colors underline"
       >
@@ -117,6 +118,7 @@ window.articlesData = [
 
           <div class="space-y-4">
             <button
+              type="button"
               @click="showEasterEgg = false; window.location.href = '{{ .Site.BaseURL }}'"
               class="w-full btn btn-primary"
             >
@@ -124,6 +126,7 @@ window.articlesData = [
             </button>
 
             <button
+              type="button"
               @click="goToRandomArticle()"
               class="w-full btn btn-secondary"
             >
@@ -132,6 +135,7 @@ window.articlesData = [
           </div>
 
           <button
+            type="button"
             @click="showEasterEgg = false"
             class="absolute top-4 right-4 text-text-dim hover:text-text dark:hover:text-text transition-colors"
             aria-label="Close modal"