mirror of
https://github.com/glanceapp/glance.git
synced 2024-12-01 21:05:02 +01:00
21 lines
301 B
Go
21 lines
301 B
Go
|
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
|
||
|
}
|