{{- /* artifactinfo.tmpl ~ Artifact information template. */ -}} {{- define "artifactinfo" -}} {{- $content := index . "content"}} {{- $alert := index . "alertURL"}} {{- $checksum := index . "checksum"}} {{- $preview := index . "linkpreview"}} {{- $previewTip := index . "linkpreviewTip"}} {{- $jsdos6 := index . "jsdos6"}} {{- $writers := trimSpace (index . "writers") }} {{- $artists := trimSpace (index . "artists") }} {{- $readmeL := index . "readmeLatin1"}} {{- $readmeLines := index . "readmeLines"}} {{- $readmeRows := index . "readmeRows"}} {{- $programmers := trimSpace (index . "programmers") }} {{- $musicians := trimSpace (index . "musicians") }} {{- $demozoo := (index . "demozoo")}} {{- $pouet := (index . "pouet")}} {{- $sixteenColors := trimSpace (index . "sixteenColors")}} {{- $youtube := trimSpace (index . "youtube")}} {{- $github := trimSpace (index . "github")}} {{- $comment := trimSpace (index . "comment")}} {{- $mimetype := mimeMagic (index . "magic")}} {{- $noDownload := index . "noDownload"}} {{- $contentDesc := index . "contentDesc"}} {{- $lastModAgo := index . "lastmodifiedAgo"}} {{- $lastMod := index . "lastmodified"}} {{- $filesize := index . "filesize"}} {{- $filebyte := index . "filebyte"}} {{- $filename := index . "filename"}} {{- $download := index . "download"}} {{- $downloadText := print "Download   " print $filesize}} {{- $fileEntry := index . "filentry"}} {{- if $noDownload}}{{$downloadText = print `` print $downloadText print ""}}{{end}} {{- /* [FILENAME] Content */}} {{- if $content}} {{- end}} {{- /* Artifact file download link */}}
{{/* text-decoration-line-through */}} {{- if eq $alert "" }} {{- /* standard download */}} {{$downloadText | safeHTML}} {{- else }} {{- /* google download warning */}} {{$downloadText | safeHTML}} {{- end }} {{- if eq $jsdos6 true}} Run app in browser {{- end}}
{{- if ne "" $checksum}} #sum Checksum {{- end}} {{- if $content}} view content {{- end}} {{- if ne "" $preview}} preview {{- end}}
{{- /* Comment on the artifact */}} {{- if ne $comment ""}}
{{$comment}}
{{- end}} {{- /* Table with details */}} {{- if ne $mimetype ""}} {{- end}} {{- if $readmeL}} {{- end}} {{- /* Authors and attributions */}} {{- if ne $writers "" }} {{- end}} {{- if ne $artists "" }} {{- end}} {{- if ne $programmers "" }} {{- end}} {{- if ne $musicians "" }} {{- end}} {{- /* Pouet, Demozoo, 16colors links */}} {{- if ne $pouet ""}} {{- end}} {{- if ne $demozoo ""}} {{- end}} {{- if ne $sixteenColors ""}} {{- end}} {{- /* YouTube, GitHub and other links */}} {{- if ne $youtube ""}} {{- end}} {{- if ne $github ""}} {{- end}} {{- /* "Link to" items */}} {{- index . "websites" }} {{- index . "relations" }} {{- /* File created and updated dates */}} {{- if $fileEntry}} {{- end}}
Download info {{$filesize}} {{- if ne "" $contentDesc}}, {{$contentDesc}}{{end -}}
Last modification {{$lastMod}}
Mime type {{$mimetype}}
Text dimensions {{$readmeLines}} x {{$readmeRows}}
 
Writers {{fmtRoles $writers}}
Artists {{fmtRoles $artists}}
Programmers {{fmtRoles $programmers}}
Musicians {{fmtRoles $musicians}}
Pouët reviews ? stars   ? votes {{$pouet}}
Demozoo Downloads, links and extras{{linkSVG}}
16colors Downloads, links and extras{{linkSVG}}
YouTube Watch on YouTube{{linkSVG}}
GitHub {{$github}}{{linkSVG}}
Artifact {{$fileEntry | safeHTML}}
{{- end}}