Files
sonr/pkg/nebula/pages/home_templ.go
T

95 lines
3.4 KiB
Go
Raw Normal View History

2024-09-14 12:47:25 -04:00
// Code generated by templ - DO NOT EDIT.
2024-09-21 21:42:51 -04:00
// templ: version: v0.2.778
2024-09-22 02:51:52 -04:00
package pages
2024-09-14 12:47:25 -04:00
//lint:file-ignore SA4006 This context is only used if a nested component is present.
import "github.com/a-h/templ"
import templruntime "github.com/a-h/templ/runtime"
import (
"github.com/labstack/echo/v4"
2024-09-29 14:40:36 -04:00
"github.com/onsonr/sonr/pkg/nebula/components/blocks"
"github.com/onsonr/sonr/pkg/nebula/components/sections"
2024-09-14 12:47:25 -04:00
)
2024-09-29 14:40:36 -04:00
func Home(c echo.Context) error {
hero := sections.Hero{
TitleFirst: "Sonr.ID",
TitleEmphasis: "platform",
TitleSecond: "for cross-functional work",
Subtitle: "Turbocharge your creative process with a powerful AI design platform that gives creatives the power of creating without limits.",
PrimaryButtonText: "Request Demo",
PrimaryButtonLink: "request-demo.html",
SecondaryButtonText: "Try for Free",
SecondaryButtonLink: "#0",
}
return echoResponse(c, homeView(hero))
2024-09-24 17:54:33 -04:00
}
2024-09-29 14:40:36 -04:00
func homeView(hero sections.Hero) templ.Component {
2024-09-14 12:47:25 -04:00
return templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) {
templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context
2024-09-21 21:42:51 -04:00
if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil {
return templ_7745c5c3_CtxErr
}
2024-09-14 12:47:25 -04:00
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W)
if !templ_7745c5c3_IsBuffer {
defer func() {
templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer)
if templ_7745c5c3_Err == nil {
templ_7745c5c3_Err = templ_7745c5c3_BufErr
}
}()
}
ctx = templ.InitializeContext(ctx)
templ_7745c5c3_Var1 := templ.GetChildren(ctx)
if templ_7745c5c3_Var1 == nil {
templ_7745c5c3_Var1 = templ.NopComponent
}
ctx = templ.ClearChildren(ctx)
templ_7745c5c3_Var2 := templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) {
templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context
templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W)
if !templ_7745c5c3_IsBuffer {
defer func() {
templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer)
if templ_7745c5c3_Err == nil {
templ_7745c5c3_Err = templ_7745c5c3_BufErr
}
}()
}
ctx = templ.InitializeContext(ctx)
2024-09-29 14:40:36 -04:00
templ_7745c5c3_Err = sections.HeaderMarketingNav().Render(ctx, templ_7745c5c3_Buffer)
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(" ")
if templ_7745c5c3_Err != nil {
2024-09-19 19:09:01 -04:00
return templ_7745c5c3_Err
2024-09-29 14:40:36 -04:00
}
templ_7745c5c3_Err = sections.SectionHero(hero).Render(ctx, templ_7745c5c3_Buffer)
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(" ")
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
templ_7745c5c3_Err = sections.FooterMarketingNav().Render(ctx, templ_7745c5c3_Buffer)
2024-09-14 12:47:25 -04:00
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
return templ_7745c5c3_Err
})
2024-09-29 14:40:36 -04:00
templ_7745c5c3_Err = blocks.LayoutNoBody("Sonr.ID", true).Render(templ.WithChildren(ctx, templ_7745c5c3_Var2), templ_7745c5c3_Buffer)
2024-09-14 12:47:25 -04:00
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
return templ_7745c5c3_Err
})
}
var _ = templruntime.GeneratedTemplate