Documentation ¶
Index ¶
- Variables
- func ErrorFromContext(ctx context.Context) error
- func FlashFromContext(ctx context.Context) string
- func NewErrorContext(parent context.Context, err error) context.Context
- func NewFlashContext(parent context.Context, s string) context.Context
- func StaticFs() fs.FS
- func TemplatesFS() fs.FS
- type DevicesDetailBlock
- type DevicesDetailPaneBlock
- type DevicesListBlock
- type DevicesNewTmpl
- type DevicesReconnectTmpl
- type DevicesTmpl
- type ErrorTmpl
- type LoginTmpl
- type RenderFunc
- type Renderable
- type Site
- type Templates
- type UsersDetailBlock
- type UsersListBlock
- type UsersRowsBlock
- type UsersTmpl
Constants ¶
This section is empty.
Variables ¶
View Source
var SiteData = &Site{
Title: "Wadoh",
}
Functions ¶
func ErrorFromContext ¶
func FlashFromContext ¶
func TemplatesFS ¶
Types ¶
type DevicesDetailBlock ¶
type DevicesDetailBlock struct { Title string Device *devices.Device DetailPane *DevicesDetailPaneBlock }
func (*DevicesDetailBlock) Renderer ¶
func (b *DevicesDetailBlock) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type DevicesDetailPaneBlock ¶
type DevicesDetailPaneBlock struct { Device *devices.Device SubAPIKey bool SubTryMessage bool SubWebhook bool SubMore bool }
func (*DevicesDetailPaneBlock) Renderer ¶
func (t *DevicesDetailPaneBlock) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type DevicesListBlock ¶
func (*DevicesListBlock) Renderer ¶
func (b *DevicesListBlock) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type DevicesNewTmpl ¶
type DevicesNewTmpl struct{}
func (*DevicesNewTmpl) Renderer ¶
func (t *DevicesNewTmpl) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type DevicesReconnectTmpl ¶
func (*DevicesReconnectTmpl) Renderer ¶
func (t *DevicesReconnectTmpl) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type DevicesTmpl ¶
type DevicesTmpl struct { Title string List *DevicesListBlock Detail *DevicesDetailBlock }
func (*DevicesTmpl) Renderer ¶
func (t *DevicesTmpl) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type RenderFunc ¶
type Renderable ¶
type Renderable interface {
Renderer(fs.FS, *Site) (layout string, fn RenderFunc)
}
type Templates ¶
type Templates struct {
// contains filtered or unexported fields
}
func NewTemplates ¶
func NewTemplates() *Templates
type UsersDetailBlock ¶
func (*UsersDetailBlock) Renderer ¶
func (t *UsersDetailBlock) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type UsersListBlock ¶
type UsersListBlock struct {
Rows *UsersRowsBlock
}
func (*UsersListBlock) Renderer ¶
func (t *UsersListBlock) Renderer(fs fs.FS, site *Site) (string, RenderFunc)
type UsersRowsBlock ¶
func (*UsersRowsBlock) Renderer ¶
func (p *UsersRowsBlock) Renderer(fs fs.FS, site *Site) (layout string, renderFn RenderFunc)
type UsersTmpl ¶
type UsersTmpl struct { Title string List *UsersListBlock Detail *UsersDetailBlock }
Click to show internal directories.
Click to hide internal directories.