render auth and password pages

This commit is contained in:
juancwu 2025-12-16 16:28:11 -05:00
commit 86fd4b73b6
4 changed files with 156 additions and 3 deletions

View file

@ -1,6 +1,11 @@
package handler
import "net/http"
import (
"net/http"
"git.juancwu.dev/juancwu/budgit/internal/ui"
"git.juancwu.dev/juancwu/budgit/internal/ui/pages"
)
type authHandler struct {
}
@ -10,6 +15,9 @@ func NewAuthHandler() *authHandler {
}
func (h *authHandler) AuthPage(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusOK)
w.Write([]byte("200 OK"))
ui.Render(w, r, pages.Auth(""))
}
func (h *authHandler) PasswordPage(w http.ResponseWriter, r *http.Request) {
ui.Render(w, r, pages.AuthPassword(""))
}