add a bunch of frontend stuff

This commit is contained in:
sam 2023-09-03 04:11:56 +02:00
parent 2586161abd
commit bc85b7c340
Signed by: sam
GPG key ID: B4EF20DDE721CAA1
30 changed files with 1459 additions and 136 deletions

15
web/auth/auth.go Normal file
View file

@ -0,0 +1,15 @@
package auth
import "git.sleepycat.moe/sam/mercury/web/app"
type Auth struct {
*app.App
}
func New(app *app.App) *Auth {
auth := &Auth{
App: app,
}
return auth
}

11
web/auth/login.go Normal file
View file

@ -0,0 +1,11 @@
package auth
import (
"net/http"
"github.com/flosch/pongo2/v6"
)
func (app *Auth) GetLogin(w http.ResponseWriter, r *http.Request) {
app.Template(w, r, "auth/login.tpl", pongo2.Context{})
}