package components
import (
"strconv"
"searchix/internal/nix"
)
templ Results(r ResultData) {
if r.Query != "" {
if r.Results != nil && r.Results.Total > 0 {
switch r.Results.Hits[0].Data.(type) {
case nix.Option:
@Options(r.Results)
case nix.Package:
@Packages(r.Results)
}
} else {
Nothing found
}
} else {
}
}
templ ResultsPage(r ResultData) {
@SearchPage(r.TemplateData, r) {
@Results(r)
}
}
templ openDialogLink(attr string) {
{ attr }
}