2024-09-29 14:40:36 -04:00
|
|
|
package pages
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"github.com/labstack/echo/v4"
|
|
|
|
|
"github.com/onsonr/sonr/pkg/nebula/components/blocks"
|
|
|
|
|
"github.com/onsonr/sonr/pkg/nebula/components/sections"
|
2024-09-30 21:16:13 -04:00
|
|
|
"github.com/onsonr/sonr/pkg/nebula/models"
|
2024-09-29 14:40:36 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func Home(c echo.Context) error {
|
2024-09-30 21:16:13 -04:00
|
|
|
mdls, err := models.GetModels()
|
|
|
|
|
if err != nil {
|
|
|
|
|
return err
|
2024-09-29 14:40:36 -04:00
|
|
|
}
|
2024-09-30 21:16:13 -04:00
|
|
|
return echoResponse(c, homeView(mdls.Hero))
|
2024-09-29 14:40:36 -04:00
|
|
|
}
|
|
|
|
|
|
2024-09-30 21:16:13 -04:00
|
|
|
templ homeView(hero *models.Hero) {
|
2024-09-29 14:40:36 -04:00
|
|
|
@blocks.LayoutNoBody("Sonr.ID", true) {
|
2024-10-01 10:34:02 -04:00
|
|
|
@sections.MarketingHeader()
|
2024-09-29 14:40:36 -04:00
|
|
|
@sections.SectionHero(hero)
|
2024-10-01 02:09:04 -04:00
|
|
|
@sections.Highlights()
|
|
|
|
|
@sections.Features()
|
|
|
|
|
@sections.Bento()
|
2024-10-01 10:34:02 -04:00
|
|
|
@sections.Lowlights()
|
|
|
|
|
@sections.CallToAction()
|
|
|
|
|
@sections.MarketingFooter()
|
2024-09-29 14:40:36 -04:00
|
|
|
}
|
|
|
|
|
}
|