diff --git a/views/pages_templ.go b/views/pages_templ.go index 2f339a8..6f11da6 100644 --- a/views/pages_templ.go +++ b/views/pages_templ.go @@ -8,9 +8,12 @@ package views import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" -import "github.com/arnef/ebooks/internal/library" +import ( + "github.com/arnef/ebooks/internal/library" + "strings" +) -func Layout(title string) templ.Component { +func Layout(title string, backHref string) templ.Component { 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 if templ_7745c5c3_CtxErr := ctx.Err(); templ_7745c5c3_CtxErr != nil { @@ -38,13 +41,36 @@ func Layout(title string) templ.Component { var templ_7745c5c3_Var2 string templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(title) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `views/pages.templ`, Line: 11, Col: 18} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `views/pages.templ`, Line: 14, Col: 18} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2)) if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } - templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 2, "