diff --git a/pkg/web/components/status.templ b/pkg/web/components/status.templ
index 28b4ee1..63ea2de 100644
--- a/pkg/web/components/status.templ
+++ b/pkg/web/components/status.templ
@@ -1,7 +1,7 @@
package components
templ Status() {
-
+
}
diff --git a/pkg/web/components/status_templ.go b/pkg/web/components/status_templ.go
index 6db8cc5..0a2f7e1 100644
--- a/pkg/web/components/status_templ.go
+++ b/pkg/web/components/status_templ.go
@@ -29,7 +29,7 @@ func Status() templ.Component {
templ_7745c5c3_Var1 = templ.NopComponent
}
ctx = templ.ClearChildren(ctx)
- templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 1, "
")
+ templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 1, "
")
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
diff --git a/pkg/web/web.go b/pkg/web/web.go
index 4f23852..77b14c3 100644
--- a/pkg/web/web.go
+++ b/pkg/web/web.go
@@ -22,6 +22,7 @@ type ValidationFeedback = models.ValidationFeedback
type Web struct {
feedbackChan chan ValidationFeedback
quitChan chan bool
+ submitChan chan<- struct{}
}
func New() *Web {
@@ -72,6 +73,10 @@ func (w *Web) Run(ctx context.Context, config Config) error {
}()
}
+ if w.submitChan != nil {
+ handler.SetSubmitChan(w.submitChan)
+ }
+
select {
case <-w.quitChan:
fmt.Println("Task completed! Shutting down server...")
@@ -89,3 +94,7 @@ func (w *Web) SetChannels(feedbackChan chan ValidationFeedback, quitChan chan bo
w.feedbackChan = feedbackChan
w.quitChan = quitChan
}
+
+func (w *Web) SetSubmitChan(submitChan chan<- struct{}) {
+ w.submitChan = submitChan
+}