forked from tangled.org/core
Monorepo for Tangled

add long dates to issue date hover

you might wanna vet the format - i didn't test this btw but i think it'll work lmao

authored by j3s.sh and committed by Tangled f0eb6bfb 03a6dfd6

Changed files
+7 -1
appview
pages
templates
repo
issues
+3
appview/pages/funcmap.go
··· 68 return s 69 }, 70 "timeFmt": humanize.Time, 71 "shortTimeFmt": func(t time.Time) string { 72 return humanize.CustomRelTime(t, time.Now(), "", "", []humanize.RelTimeMagnitude{ 73 {time.Second, "now", time.Second},
··· 68 return s 69 }, 70 "timeFmt": humanize.Time, 71 + "longTimeFmt": func(t time.Time) string { 72 + return t.Format("2006-01-02 * 3:04 PM") 73 + }, 74 "shortTimeFmt": func(t time.Time) string { 75 return humanize.CustomRelTime(t, time.Now(), "", "", []humanize.RelTimeMagnitude{ 76 {time.Second, "now", time.Second},
+4 -1
appview/pages/templates/repo/issues/issue.html
··· 29 >{{ $owner }}</a 30 > 31 <span class="px-1 select-none before:content-['\00B7']"></span> 32 - <time>{{ .Issue.Created | timeFmt }}</time> 33 </span> 34 </div> 35 ··· 69 href="#{{ .CommentId }}" 70 class="text-gray-500 text-sm hover:text-gray-500 hover:underline no-underline dark:text-gray-400 dark:hover:text-gray-300 dark:hover:bg-gray-800" 71 id="{{ .CommentId }}" 72 > 73 {{ .Created | timeFmt }} 74 </a>
··· 29 >{{ $owner }}</a 30 > 31 <span class="px-1 select-none before:content-['\00B7']"></span> 32 + <time title="{{ .Issue.Created | longTimeFmt }}"> 33 + {{ .Issue.Created | timeFmt }} 34 + </time> 35 </span> 36 </div> 37 ··· 71 href="#{{ .CommentId }}" 72 class="text-gray-500 text-sm hover:text-gray-500 hover:underline no-underline dark:text-gray-400 dark:hover:text-gray-300 dark:hover:bg-gray-800" 73 id="{{ .CommentId }}" 74 + title="{{ .Created | longTimeFmt }}" 75 > 76 {{ .Created | timeFmt }} 77 </a>