Added a basic homepage
This commit is contained in:
parent
d40640a648
commit
12fd3c04ca
113 changed files with 414 additions and 506 deletions
|
|
@ -1,31 +0,0 @@
|
|||
package forms
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"github.com/camzawacki/personal-site/pkg/routenames"
|
||||
"github.com/camzawacki/personal-site/pkg/ui"
|
||||
. "github.com/camzawacki/personal-site/pkg/ui/components"
|
||||
. "maragu.dev/gomponents"
|
||||
. "maragu.dev/gomponents/html"
|
||||
)
|
||||
|
||||
type File struct{}
|
||||
|
||||
func (f File) Render(r *ui.Request) Node {
|
||||
return Form(
|
||||
ID("files"),
|
||||
Method(http.MethodPost),
|
||||
Action(r.Path(routenames.FilesSubmit)),
|
||||
EncType("multipart/form-data"),
|
||||
FileField(FileFieldParams{
|
||||
Name: "file",
|
||||
Label: "Test file",
|
||||
Help: "Pick a file to upload.",
|
||||
}),
|
||||
ControlGroup(
|
||||
FormButton(ColorPrimary, "Upload"),
|
||||
),
|
||||
CSRF(r),
|
||||
)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue