diff --git a/glance-system/glance-kisfenyo.yaml b/glance-system/glance-kisfenyo.yaml index 6c7ea08..1452661 100644 --- a/glance-system/glance-kisfenyo.yaml +++ b/glance-system/glance-kisfenyo.yaml @@ -788,138 +788,69 @@ data: tandoor_url: https://tandoor.dooplex.hu template: | - - {{ $tandoor := .Options.StringOr "tandoor_url" "https://tandoor.dooplex.hu" }} {{ $items := .JSON.Array "items" }} - {{ $total := .JSON.Int "total_recipes" }} - {{ $date := .JSON.String "date" }} {{ $count := len $items }} + {{ $last := sub $count 1 }} -
-
+ + +
+
Today's picks ({{ $count }} total) Open Tandoor
- - {{ if lt $count 1 }} -
No recipes returned.
- {{ else }} -
-
- {{ range $i, $r := $items }} - {{ $name := $r.String "name" }} - {{ $img := $r.String "image" }} - {{ $url := $r.String "url" }} - {{ $cook := $r.String "cook_url" }} - - - {{ end }} + {{ if lt $count 1 }}
No recipes.
{{ else }} +
+ {{ range $i, $_ := $items }}{{ end }} +
+ {{ range $r := $items }}{{ $img := $r.String "image" }}{{ $url := $r.String "url" }}{{ $cook := $r.String "cook_url" }} + - {{ if gt $count 1 }} - - {{ end }}
{{ if gt $count 1 }} -
- {{ range $i, $r := $items }} - - {{ end }} -
+ {{ range $i, $_ := $items }}{{ if gt $i 0 }}{{ end }}{{ if lt $i $last }}{{ end }}{{ end }} +
{{ range $i, $_ := $items }}{{ end }}
{{ end }} +
{{ end }}
- {{ if gt $count 1 }} - - {{ end }} - - type: bookmarks title: Productivity Self-Hosted groups: