add completion message to task modal and make it wider
This commit is contained in:
@@ -14,7 +14,7 @@ templ Modal(props ModalProps) {
|
||||
{{
|
||||
maxWidth := props.MaxWidth
|
||||
if maxWidth == "" {
|
||||
maxWidth = "max-w-xl"
|
||||
maxWidth = "max-w-2xl"
|
||||
}
|
||||
}}
|
||||
<div
|
||||
|
||||
@@ -41,7 +41,7 @@ func Modal(props ModalProps) templ.Component {
|
||||
ctx = templ.ClearChildren(ctx)
|
||||
maxWidth := props.MaxWidth
|
||||
if maxWidth == "" {
|
||||
maxWidth = "max-w-xl"
|
||||
maxWidth = "max-w-2xl"
|
||||
}
|
||||
var templ_7745c5c3_Var2 = []any{"fixed inset-0 z-50 items-center justify-center mx-auto", maxWidth}
|
||||
templ_7745c5c3_Err = templ.RenderCSSItems(ctx, templ_7745c5c3_Buffer, templ_7745c5c3_Var2...)
|
||||
|
||||
@@ -58,6 +58,11 @@ func HandleTaskStatusModal(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
func feedbackList(feedback ValidationFeedback) templ.Component {
|
||||
return templ.ComponentFunc(func(ctx context.Context, w io.Writer) error {
|
||||
if feedback.Success {
|
||||
io.WriteString(w, `<p class="my-2">`+feedback.Message+`</p>`)
|
||||
io.WriteString(w, `<p class="my-2 text-xl">You can close the browser and return to the terminal window</p>`)
|
||||
}
|
||||
|
||||
for _, check := range feedback.Checks {
|
||||
if !check.Valid {
|
||||
io.WriteString(w, `<p class="my-2 text-sm">`+"❌ "+check.Message+`</p>`)
|
||||
|
||||
Reference in New Issue
Block a user