fix merge
This commit is contained in:
@@ -39,29 +39,17 @@ templ Head(props HeadProps) {
|
|||||||
type HeadProps struct {
|
type HeadProps struct {
|
||||||
Links []Link
|
Links []Link
|
||||||
Scripts []Script
|
Scripts []Script
|
||||||
Links []Link
|
|
||||||
Scripts []Script
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type Link struct {
|
type Link struct {
|
||||||
Href string
|
Href string
|
||||||
Rel string
|
Rel string
|
||||||
|
As string
|
||||||
}
|
}
|
||||||
|
|
||||||
type Script struct {
|
type Script struct {
|
||||||
Src string
|
Src string
|
||||||
Defer bool
|
Defer bool
|
||||||
Src string
|
|
||||||
Defer bool
|
|
||||||
}
|
|
||||||
|
|
||||||
templ Head(props HeadProps) {
|
|
||||||
for _, link := range props.Links {
|
|
||||||
<link href={ link.Href } rel={ link.Rel }/>
|
|
||||||
}
|
|
||||||
for _, script := range props.Scripts {
|
|
||||||
<script src={ script.Src } defer={ script.Defer }></script>
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
templ Header(props HeaderProps) {
|
templ Header(props HeaderProps) {
|
||||||
@@ -141,20 +129,15 @@ type HeaderProps struct {
|
|||||||
CreateHref string
|
CreateHref string
|
||||||
SearchPlaceholder string
|
SearchPlaceholder string
|
||||||
Routes []NavRoute
|
Routes []NavRoute
|
||||||
Routes []NavRoute
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type NavRoute struct {
|
type NavRoute struct {
|
||||||
Name string
|
Name string
|
||||||
Path string
|
Path string
|
||||||
Name string
|
|
||||||
Path string
|
|
||||||
}
|
}
|
||||||
|
|
||||||
templ Footer(props FooterProps) {
|
|
||||||
templ Footer(props FooterProps) {
|
templ Footer(props FooterProps) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type FooterProps struct {
|
type FooterProps struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user