diff options
Diffstat (limited to 'themes/default/layouts/_default/home.sources.html')
-rw-r--r-- | themes/default/layouts/_default/home.sources.html | 120 |
1 files changed, 120 insertions, 0 deletions
diff --git a/themes/default/layouts/_default/home.sources.html b/themes/default/layouts/_default/home.sources.html new file mode 100644 index 0000000..aa77e2a --- /dev/null +++ b/themes/default/layouts/_default/home.sources.html @@ -0,0 +1,120 @@ +{{ define "title" }}Sources — {{ end }} +{{ define "description" }}This page contains a list of all source files — {{ end }} +{{ define "styles" }} +<style> + {{ partial "styles-navigator.html" (dict "Link" "/sources/") | safeCSS }} +</style> +{{ end }} + +{{ define "middle" }} + + {{ $_default := readDir (print "/themes/default/layouts/_default") }} + {{ $_markup := readDir (print "/themes/default/layouts/_default/_markup") }} + {{ $partials := readDir (print "/themes/default/layouts/partials") }} + {{ $shortcodes := readDir (print "/themes/default/layouts/shortcodes") }} + + {{ $fileCount := add (len $shortcodes) (len $partials) }} + + {{ partial "navigator-middle.html" + (dict + "Title" "Sources" + "Subtitle" (print $fileCount " " "Files") + "Icon" "arrow-left" + "IconLabel" "Back" + "Href" "/" + "Id" "back" + "Context" . + ) + }} + + <source-array> + <item-list> + + <h1>Defaults</h1> + <ul> + {{ range sort $_default ".ModTime" "desc" }} + {{ if not .IsDir }} + <li> + <a download title="{{ .Name }}" href="/source/files/_default/{{ .Name }}"> + <code> + <span>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</span> + <span>{{ .Name }}</span> + <span>{{ .Size -}}</span> + </code> + </a> + </li> + {{ end }} + {{ end }} + </ul> + + <h1>Markup</h1> + <ul> + {{ range sort $_markup ".ModTime" "desc" }} + {{ if not .IsDir }} + <li> + <a download title="{{ .Name }}" href="/source/files/_default/_markup/{{ .Name }}"> + <code> + <span>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</span> + <span>{{ .Name }}</span> + <span>{{ .Size -}}</span> + </code> + </a> + </li> + {{ end }} + {{ end }} + </ul> + + <h1>Partials</h1> + <ul> + {{ range sort $partials ".ModTime" "desc" }} + {{ if not .IsDir }} + <li> + <a download title="{{ .Name }}" href="/source/files/partials/{{ .Name }}"> + <code> + <span>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</span> + <span>{{ .Name }}</span> + <span>{{ .Size -}}</span> + </code> + </a> + </li> + {{ end }} + {{ end }} + </ul> + + <h1>Shortcodes</h1> + <ul> + {{ range sort $shortcodes ".ModTime" "desc" }} + {{ if not .IsDir }} + <li> + <a download title="{{ .Name }}" href="/source/files/shortcodes/{{ .Name }}"> + <code> + <span>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</span> + <span>{{ .Name }}</span> + <span>{{ .Size -}}</span> + </code> + </a> + </li> + {{ end }} + {{ end }} + </ul> + </item-list> + + <footer> + <p> + Canory Version: 0.1.1 + · Dictionary Access by Paul Lutus: <a href="https://arachnoid.com/javascript/dictionary_access.js">GPLv2+ License</a> + · Feather Icons by Cole Bemis: <a href="https://github.com/feathericons/feather/blob/8b5d6802fa8fd1eb3924b465ff718d2fa8d61efe/LICENSE">MIT License</a> + · Tabler Icons by PaweÅ‚ Kuna: <a href="https://github.com/tabler/tabler-icons/blob/60f39297d0f785f2e8635faca6857b2260b2d164/LICENSE">MIT License</a> + · Instant Page by Alexandre Dieulot: <a href="https://github.com/instantpage/instant.page/blob/729e97d5b3245552e41d8f92ed03d08f1d62ea46/LICENSE">MIT License</a> + · Fixed Search by Heracles Papatheodorou: <a href="https://gist.github.com/Arty2/8b0c43581013753438a3d35c15091a9f#file-license-md">License</a> + · Fuzzy Sort by Stephen Kamenar: <a href="https://github.com/farzher/fuzzysort/blob/e7f484a124f09bf3cb9a4db366a95457d962dbed/LICENSE">MIT License</a> + </p> + </footer> + + </source-array> + +{{ end }} + +{{ define "right" }} + {{- partial "navigator-right-default.html" . -}} +{{ end }} |