glance/internal/widget/html.go

21 lines
301 B
Go
Raw Normal View History

2024-06-02 20:01:20 +02:00
package widget
import (
"html/template"
)
type HTML struct {
widgetBase `yaml:",inline"`
Source template.HTML `yaml:"source"`
}
func (widget *HTML) Initialize() error {
widget.withTitle("").withError(nil)
return nil
}
func (widget *HTML) Render() template.HTML {
return widget.Source
}