newsbot-portal/internal/views/users/login copy.templ

34 lines
720 B
Plaintext
Raw Normal View History

2024-07-09 08:32:38 -07:00
package users
import (
"git.jamestombleson.com/jtom38/newsbot-portal/templ-bulma/form"
2024-07-09 08:32:38 -07:00
"git.jamestombleson.com/jtom38/newsbot-portal/internal/views/layout"
"git.jamestombleson.com/jtom38/newsbot-portal/internal/models"
2024-07-09 08:32:38 -07:00
)
var (
p = form.NewParam{
HxPost: "/users/login",
}
)
templ LoginNew(vm models.UsersLoginViewModel) {
@layout.WithTemplate(vm.HeaderMetaTags) {
@form.New(p) {
2024-07-09 08:32:38 -07:00
@form.Field() {
@form.Label("Username")
@form.Control() {
2024-07-13 10:38:54 -07:00
@form.TextInput("username", "text", "email address")
2024-07-09 08:32:38 -07:00
}
}
@form.Field() {
2024-07-09 08:32:38 -07:00
@form.Label("Password")
@form.Control() {
2024-07-13 10:38:54 -07:00
@form.TextInput("password", form.InputTypePassword, "")
2024-07-09 08:32:38 -07:00
}
}
@form.Submit("Submit", "is-primary")
}
}
}