From adddec5617adf957a2d31ddca804487983da7061 Mon Sep 17 00:00:00 2001 From: Jona Heitzer Date: Sat, 4 Jan 2025 17:14:53 +0100 Subject: [PATCH] DIsable submit button when clicked --- static/index.html.tmpl | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/static/index.html.tmpl b/static/index.html.tmpl index 86409e3..22813a8 100644 --- a/static/index.html.tmpl +++ b/static/index.html.tmpl @@ -66,6 +66,12 @@ border-radius: 5px; cursor: pointer; } + + #submit-btn:disabled { + background-color: #ccc; + color: #666; + cursor: not-allowed; + } #submit-btn:hover { background-color: #45a049; @@ -166,6 +172,8 @@ return; } + submitBtn.disabled = true; + const days = calendar.children; const choices = Array.from(days).map(day => Array.from(day.children)