package web
import "fmt"
templ (w *Web) Header(title string) {
if title != "" {
{ w.botName() } - { title }
} else {
{ w.botName() }
}
}
templ (w *Web) Footer() {
}
templ (w *Web) Index(title string, contents templ.Component) {
@w.Header(title)
@w.Nav(title)
if contents != nil {
@contents
}
@w.Footer()
}
templ (w *Web) Nav(currentPage string) {
}
templ (w *Web) showStats() {
Stats
Messages Seen |
{ fmt.Sprintf("%d", w.stats.MessagesRcv) } |
Messages Sent |
{ fmt.Sprintf("%d", w.stats.MessagesSent) } |
Uptime |
{ fmt.Sprintf("%v", w.stats.Uptime()) } |
}