package auth import ( "gitea.henriburau.de/haw-lan/cod4watcher/views/layouts" "gitea.henriburau.de/haw-lan/cod4watcher/views/components" ) type LoginFormValues struct { Username string Password string } templ LoginForm(formValues LoginFormValues, errors map[string]string) { @layouts.Base() { @components.Form(components.FormProps{ Title: "Log into your account", Action: "/signin", Method: "post", SubmitText: "Login", }) {
@components.Input(components.InputProps{ Name: "username", Value: formValues.Username, Error: errors["username"], Placeholder: "Your username", })
@components.Input(components.InputProps{ Name: "password", Value: formValues.Password, Error: errors["password"], Placeholder: "Your password", })
} } }