Add share link UI after upload

This commit is contained in:
2026-09-13 00:17:37 +02:00
parent da36645aaf
commit 505e4f472f
8 changed files with 211 additions and 47 deletions
+4 -1
View File
@@ -426,11 +426,14 @@ func (s *Server) respondUploaded(w http.ResponseWriter, r *http.Request, m *stor
// Rendered directly rather than redirected: a 303 would have to carry the
// delete token in the URL, where it would end up in logs and history.
s.render(w, http.StatusOK, "result.html", objectPage{
page: s.page("Uploaded", false),
// The script is loaded here only to enable the copy buttons, which stay
// hidden without it rather than sitting there dead.
page: s.page("Uploaded", true),
Meta: m,
Size: config.FormatSize(m.Size),
Expires: describeExpiry(m.Expires, s.now()),
URL: url,
InfoURL: s.absBase(r) + "i/" + m.ID,
DeleteToken: secret,
})
}