diff --git a/internal/templates/archive.templ b/internal/templates/archive.templ index 3957051..fb1316c 100644 --- a/internal/templates/archive.templ +++ b/internal/templates/archive.templ @@ -73,69 +73,73 @@ templ Archive(years []YearInfo) {
- for _, year := range years { -
-
-

{ strconv.Itoa(year.Year) }

- for _, p := range year.RecapParagraphs { -

{ p }

- } -
-
-
- for _, r := range year.Results { -
-

- -

-
-
+} + +templ year(y YearInfo) { +
+
+

{ strconv.Itoa(y.Year) }

+ for _, p := range y.RecapParagraphs { +

{ p }

+ } +
+
+
+ for _, r := range y.Results { +
+

+

- } + { r.Name } Competition Winners + +
-
-
-
- for i, link := range year.Links { - if i > 0 { -  • +
+
+ for i, t := range r.Teams { + @winningTeam(i, t) } - { link.Title } - } +
-
+ }
- } +
+
+
+ for i, link := range y.Links { + if i > 0 { +  • + } + { link.Title } + } +
+
} + +templ winningTeam(i int, team WinningTeam) { +
  • + + + { team.Place } + + { team.Name } +

    + { team.School } • { team.Location } +

    +
  • +} diff --git a/internal/templates/partials/pagenames.go b/internal/templates/partials/pagenames.go index 17422bd..f9ca2c7 100644 --- a/internal/templates/partials/pagenames.go +++ b/internal/templates/partials/pagenames.go @@ -1,5 +1,6 @@ package partials +// TODO consider moving this somewhere else type PageName string const (