Wrap nav links into a list.
This commit is contained in:
parent
c0e4981d62
commit
e313a52daf
@ -147,9 +147,10 @@ header.main nav {
|
|||||||
font-variant: small-caps;
|
font-variant: small-caps;
|
||||||
width: 300px; }
|
width: 300px; }
|
||||||
|
|
||||||
header.main nav div {
|
header.main nav ul {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-evenly;
|
justify-content: space-evenly;
|
||||||
|
list-style: none;
|
||||||
width: 100%; }
|
width: 100%; }
|
||||||
|
|
||||||
section {
|
section {
|
||||||
|
@ -51,17 +51,17 @@ templ navigation(title string) {
|
|||||||
{{ sections := []string{"Stuff", "Mindflow", "About", "Guestbook"} }}
|
{{ sections := []string{"Stuff", "Mindflow", "About", "Guestbook"} }}
|
||||||
{{ links := []templ.SafeURL{"/stuff", "/mindflow", "/about", "/guestbook"} }}
|
{{ links := []templ.SafeURL{"/stuff", "/mindflow", "/about", "/guestbook"} }}
|
||||||
<nav>
|
<nav>
|
||||||
<div>
|
<ul>
|
||||||
if title != "" {
|
if title != "" {
|
||||||
<a href="/">Home</a>
|
<li><a href="/">Home</a></li>
|
||||||
}
|
}
|
||||||
for i, s := range sections {
|
for i, s := range sections {
|
||||||
if strings.HasSuffix(title, s) {
|
if strings.HasSuffix(title, s) {
|
||||||
{{ continue }}
|
{{ continue }}
|
||||||
}
|
}
|
||||||
<a href={ links[i] }>{ s }</a>
|
<li><a href={ links[i] }>{ s }</a></li>
|
||||||
}
|
}
|
||||||
</div>
|
</ul>
|
||||||
if title != "" {
|
if title != "" {
|
||||||
<h1>
|
<h1>
|
||||||
if strings.HasSuffix(title, "- Stuff") {
|
if strings.HasSuffix(title, "- Stuff") {
|
||||||
|
Loading…
Reference in New Issue
Block a user