From 737343b66b336295455edc155e21789407bd497f Mon Sep 17 00:00:00 2001 From: DonVoo Date: Mon, 13 Jul 2026 02:59:57 +0200 Subject: [PATCH] Return source mailbox partial for HTMX --- backend/00-router.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/backend/00-router.go b/backend/00-router.go index 9653ea3..d659dea 100644 --- a/backend/00-router.go +++ b/backend/00-router.go @@ -301,6 +301,11 @@ func emailBoxHandler(w http.ResponseWriter, r *http.Request) { kind := strings.TrimPrefix(r.URL.Path, "/boxes/") switch kind { case "source": + if r.Header.Get("HX-Request") == "true" { + w.Header().Set("Content-Type", "text/html; charset=utf-8") + fmt.Fprint(w, renderEmailBoxSourcePane(accounts, r.URL.Query().Get("source"))) + return + } renderSourceEmailBoxPage(w, r, accounts, r.URL.Query().Get("source")) case "target": renderTargetEmailBoxPage(w, r, accounts)