Rebuilding the Machine Listening Curriculum beginning in 2024
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

112 satır
6.3 KiB

  1. {{ $s := partialCached "scratch.html" . }}
  2. {{ $currentDir := "" }}
  3. {{ with .File }}
  4. {{ $currentDir = .Dir }}
  5. {{ end }}
  6. {{ $currentFile := (printf "/%s" .File) }}
  7. {{ $scratch := $s.Get $currentFile }}
  8. {{ $is_in_ := newScratch }}
  9. {{ with eq $scratch.depth "crust" }}
  10. {{ range $scratch.is_in }}
  11. {{ range $k,$v := $s.Get (printf "/%s" .File) }}
  12. {{ if eq $k "is_in" }}
  13. {{ range $v }}
  14. {{ $is_in_.Set (printf "/%s" .File) (printf "/%s" .File) }}
  15. {{ end }}
  16. {{ end }}
  17. {{ end }}
  18. {{ end }}
  19. {{ end }}
  20. {{ $is_in_is_in := (slice) }}
  21. {{ range $is_in_.Values }}
  22. {{ $is_in_is_in = $is_in_is_in | append ($.GetPage .) }}
  23. {{ end }}
  24. {{ if eq hugo.Environment "gitea" }}
  25. <div class="headiter" id="preview">
  26. <a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_edit/master/content/{{ .File }}">EDIT_THIS</a>
  27. {{ with $scratch.core }}<a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_new/master/content/{{ index . 0 }}/">ADD_{{ index . 0 | upper }}</a>{{ end }}
  28. {{ with $scratch.mantle }}<a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_new/master/content/{{ index . 0 }}/">ADD_{{ index . 0 | upper }}</a>{{ end }}
  29. {{ with $scratch.crust }}<a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_new/master/content/{{ index . 0 }}/">ADD_{{ index . 0 | upper }}</a>{{ end }}
  30. {{ if not $scratch.core }}<a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_new/master/content/{{ $currentDir }}">ADD_{{ substr $currentDir 0 -1 | upper }}</a>{{ end }}
  31. <a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}/_edit/master/PUBLISH.trigger.md">PUBLISH</a>
  32. <a class="edit-button" target="_blank" href="{{ $.Site.Params.sandpointsGiteaUrl }}"> ? </a>
  33. </div>
  34. {{ else }}
  35. {{ $editPage := $.Site.GetPage "/edit" }}
  36. <div class="headiter" id="preview">
  37. <a class="edit-button" href="{{ $editPage.RelPermalink }}index.html?edit={{ .File.UniqueID }}">EDIT_THIS</a>
  38. {{ with $scratch.core }}<a class="edit-button" href="{{ $editPage.RelPermalink }}index.html?new={{ index . 0 }}">ADD_{{ index . 0 | upper }}</a>{{ end }}
  39. {{ with $scratch.mantle }}<a class="edit-button" href="{{ $editPage.RelPermalink }}index.html?new={{ index . 0 }}">ADD_{{ index . 0 | upper }}</a>{{ end }}
  40. {{ with $scratch.crust }}<a class="edit-button" href="{{ $editPage.RelPermalink }}index.html?new={{ index . 0 }}">ADD_{{ index . 0 | upper }}</a>{{ end }}
  41. {{ if not $scratch.core }}<a class="edit-button" href="{{ $editPage.RelPermalink }}index.html?new={{ $currentDir }}">ADD_{{ substr $currentDir 0 -1 | upper }}</a>{{ end }}
  42. </div>
  43. </div>
  44. {{ end }}
  45. <div class="header">
  46. <a title="{{ $.Site.Home.Title }}'s Bibliotheke" href="/library/BROWSE_LIBRARY.html" class="bibliotheke" target="_blank">
  47. <img src="/images/bibliotheke.svg" />
  48. </a>
  49. <div class="breadcrumbs">
  50. {{ if eq $scratch.depth "mantle" }}
  51. {{ with gt (len $scratch.is_in) 1 }}
  52. <div class="ddmenu">
  53. <input id="toggly0" type="checkbox">
  54. <label for="toggly0" tabindex="1"><span class="sup">cf.&nbsp;</span><a href="{{ with (index $scratch.is_in 0) }}{{ .RelPermalink }}{{ end }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ with index $scratch.is_in 0 }}<i>{{ .Title }}</i></a>&nbsp;{{ end }}</label>
  55. <div class="hiddendiv">
  56. <ul class="mt-4">
  57. {{ range after 1 $scratch.is_in }}
  58. <li><a href="{{ .RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}"><i>{{ .Title }}</i></a></li>
  59. {{ end }}
  60. </ul>
  61. </div>
  62. </div>
  63. {{ else }}
  64. <a href="{{ with (index $scratch.is_in 0) }}{{ .RelPermalink }}{{ end }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}"><span class="supt">{{ with (index $scratch.is_in 0) }}{{ substr .Title 0 1 }}</span><i>{{ substr .Title 1 }}</i></a>{{ end }}
  65. {{ end }}
  66. <span class="mantlebar"><i> » <a href="{{ .RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ .Title }}</a></i></span>
  67. {{ end }}
  68. {{ if eq $scratch.depth "crust" }}
  69. {{ with gt (len $is_in_is_in) 1 }}
  70. <div class="ddmenu">
  71. <input id="toggly1" type="checkbox">
  72. <label for="toggly1" tabindex="1"><span class="sup">cf.&nbsp;</span><a href="{{ with (index $is_in_is_in 0) }}{{ .RelPermalink }}{{ end }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ with (index $is_in_is_in 0) }}<i>{{ .Title }}</i></a>&nbsp;{{ end }}</label>
  73. <div class="hiddendiv">
  74. <ul class="mt-4">
  75. {{ range after 1 $is_in_is_in }}
  76. <li><a href="{{ .RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}"><i>{{ .Title }}</i></a></li>
  77. {{ end }}
  78. </ul>
  79. </div>
  80. </div>
  81. {{ else }}
  82. {{ $home := index $is_in_is_in 0 }}
  83. <a href="{{ $home.RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}"><span class="supt">{{ substr $home.Title 0 1 }}</span><i>{{ substr $home.Title 1 }}</i></a>
  84. {{ end }}
  85. {{ with gt (len $scratch.is_in) 1 }}
  86. »&nbsp;
  87. <div class="ddmenu">
  88. <input id="toggly" type="checkbox">
  89. <label for="toggly" tabindex="1"><span class="sup">cf.&nbsp;</span><a href="{{ with (index $scratch.is_in 0) }}{{ .RelPermalink }}{{ end }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ with (index $scratch.is_in 0) }}<i>{{ .Title }}</i></a>&nbsp;{{ end }}</label>
  90. <div class="hiddendiv">
  91. <ul class="mt-4">
  92. {{ range after 1 $scratch.is_in }}
  93. <li><a href="{{ .RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}"><i>{{ .Title }}</i></a></li>
  94. {{ end }}
  95. </ul>
  96. </div>
  97. </div>
  98. {{ else }}»&nbsp;<a href="{{ with (index $scratch.is_in 0) }}{{ .RelPermalink }}{{ end }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ with (index $scratch.is_in 0) }}<i>{{ .Title }}</i></a>{{ end }}
  99. {{ end }}
  100. <span class="mantlebar"><i> » <a href="{{ .RelPermalink }}{{ if eq hugo.Environment "offline" }}index.html{{ end }}">{{ .Title }}</a></i></span>
  101. {{ end }}
  102. </div>
  103. </div>