{{ $secDir := "" }} {{ if .CurrentSection }} {{ if .CurrentSection.File }} {{ $secDir = .CurrentSection.File.Dir }} {{ end }} {{ end }} {{ if or (eq $secDir "yasha/diary/") (eq $secDir "semen/diary/") }}
Фильтры
  • Все записи
{{ $diaryTags := slice }} {{ range .CurrentSection.Pages }} {{ range .Params.tags }} {{ $diaryTags = $diaryTags | append . }} {{ end }} {{ end }} {{ $diaryTags = $diaryTags | uniq }} {{ if $diaryTags }}
Теги
    {{ range $diaryTags }}
  • {{ . }}
  • {{ end }}
{{ end }} {{ else if or (eq $secDir "yasha/kb/") (eq $secDir "semen/kb/") }}
Фильтры
  • Все статьи
{{ $kbTags := slice }} {{ range .CurrentSection.Pages }} {{ range .Params.tags }} {{ $kbTags = $kbTags | append . }} {{ end }} {{ end }} {{ $kbTags = $kbTags | uniq }} {{ if $kbTags }}
Теги
    {{ range $kbTags }}
  • {{ . }}
  • {{ end }}
{{ end }} {{ else if eq $secDir "yasha/plans/" }}
Статусы
  • Все планы
  • 🟡 Запланировано
  • 🟠 В процессе
  • ✅ Сделано
  • ❌ Отменено
{{ else if eq $secDir "yasha/guides/" }}
Фильтры
  • Все инструкции
{{ $guideTags := slice }} {{ range .CurrentSection.Pages }} {{ range .Params.tags }} {{ $guideTags = $guideTags | append . }} {{ end }} {{ end }} {{ $guideTags = $guideTags | uniq }} {{ if $guideTags }}
Теги
    {{ range $guideTags }}
  • {{ . }}
  • {{ end }}
{{ end }} {{ else if eq $secDir "yasha/creds/" }}
Фильтры
  • Все креды
{{ $credServices := slice }} {{ range .CurrentSection.Pages }} {{ if .Params.service }} {{ $credServices = $credServices | append .Params.service }} {{ end }} {{ end }} {{ $credServices = $credServices | uniq }} {{ if $credServices }}
Сервисы
    {{ range $credServices }}
  • {{ . }}
  • {{ end }}
{{ end }} {{ else if eq $secDir "yasha/leadera/" }}
Фильтры
  • Все статьи
{{ else }}
Разделы
  • Яша
  • Семен
{{ end }}