tmpl

package
v0.0.0-...-9ff5dc0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteForm

func DeleteForm(state AppState, videoFormState VideoFormState, video videostore.Video) templ.Component

func EditForm

func EditForm(state AppState, videoFormState VideoFormState, video videostore.Video) templ.Component

func ErrorPage

func ErrorPage(state AppState, message string) templ.Component

func Home

func Home(state AppState, paging Paging, videos []videostore.Video) templ.Component
func Search(state AppState, paging Paging, videos []videostore.Video) templ.Component

func UploadForm

func UploadForm(state AppState, videoFormState VideoFormState) templ.Component

func Watch

func Watch(state AppState, video videostore.Video) templ.Component

Types

type AppState

type AppState struct {
	ReadOnly      bool
	SortDirection string
	Sortable      bool
	SearchText    string

	XSRFToken func() string

	PUG PublicURLGenerator
}

type Paging

type Paging struct {
	URL         func(p int) string
	CurrentPage int
	Pages       int
}

type PublicURLGenerator

type PublicURLGenerator func(relativeURL string) string

type VideoFormState

type VideoFormState struct {
	Error       string
	Title       string
	Tags        string
	Description string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL