summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorChristian Krinitsin <mail@krinitsin.com>2025-04-21 18:30:41 +0200
committerChristian Krinitsin <mail@krinitsin.com>2025-04-21 18:30:41 +0200
commit1e974f70a6c262d0b5db8b177ebb02b46446bfb0 (patch)
treef2b46ec33e67a811e2d43b1963cac1c58d35f935
parent996f7a0d798452bd7ca134ada2871bc24c91e519 (diff)
downloadshopping-list-1e974f70a6c262d0b5db8b177ebb02b46446bfb0.tar.gz
shopping-list-1e974f70a6c262d0b5db8b177ebb02b46446bfb0.zip
add autofocus on the input field and add a delete-confirmation prompt
-rw-r--r--templates/template.html4
1 files changed, 2 insertions, 2 deletions
diff --git a/templates/template.html b/templates/template.html
index bbb10cb..7548624 100644
--- a/templates/template.html
+++ b/templates/template.html
@@ -186,11 +186,11 @@
 
         <form action="{{ .base_path }}create" method="POST">
             <div class="input-container">
-                <input type="text" id="newItem" name="newItem" tabindex="0"/>
+                <input type="text" id="newItem" name="newItem" tabindex="0" autofocus/>
             </div>
         </form>
 
-            <form action="{{ .base_path }}delete" method="POST">
+            <form action="{{ .base_path }}delete" method="POST" onsubmit="return confirm('Are you sure you want to delete all checked entries?')">
             <button type="submit" class="delete-button">Delete Selected Items</button>
         </form>