A vibe coded tangled fork which supports pijul.
at dfc91bcd596cf42b03808dbc6d7955dcf582b8d4 56 lines 2.1 kB view raw
1{{ define "repo/issues/fragments/editIssueComment" }} 2 {{ with .Comment }} 3 <div id="comment-container-{{ .CommentId }}"> 4 <div 5 class="flex items-center gap-2 mb-2 text-gray-500 dark:text-gray-400 text-sm flex-wrap"> 6 {{ $owner := didOrHandle $.LoggedInUser.Did $.LoggedInUser.Handle }} 7 <a href="/{{ $owner }}" class="no-underline hover:underline"> 8 {{ $owner }} 9 </a> 10 11 <!-- show user "hats" --> 12 {{ $isIssueAuthor := eq .OwnerDid $.Issue.OwnerDid }} 13 {{ if $isIssueAuthor }} 14 <span class="before:content-['·']"></span> 15 author 16 {{ end }} 17 18 19 <span class="before:content-['·']"></span> 20 <a 21 href="#{{ .CommentId }}" 22 class="text-gray-500 dark:text-gray-400 hover:text-gray-500 dark:hover:text-gray-400 hover:underline no-underline" 23 id="{{ .CommentId }}"> 24 {{ template "repo/fragments/time" .Created }} 25 </a> 26 27 <button 28 class="btn px-2 py-1 flex items-center gap-2 text-sm group" 29 hx-post="/{{ $.RepoInfo.FullName }}/issues/{{ .Issue }}/comment/{{ .CommentId }}/edit" 30 hx-include="#edit-textarea-{{ .CommentId }}" 31 hx-target="#comment-container-{{ .CommentId }}" 32 hx-swap="outerHTML"> 33 {{ i "check" "w-4 h-4" }} 34 {{ i "loader-circle" "w-4 h-4 animate-spin hidden group-[.htmx-request]:inline" }} 35 </button> 36 <button 37 class="btn px-2 py-1 flex items-center gap-2 text-sm" 38 hx-get="/{{ $.RepoInfo.FullName }}/issues/{{ .Issue }}/comment/{{ .CommentId }}/" 39 hx-target="#comment-container-{{ .CommentId }}" 40 hx-swap="outerHTML"> 41 {{ i "x" "w-4 h-4" }} 42 </button> 43 <span id="comment-{{ .CommentId }}-status"></span> 44 </div> 45 46 <div> 47 <textarea 48 id="edit-textarea-{{ .CommentId }}" 49 name="body" 50 class="w-full p-2 border rounded min-h-[100px]"> 51{{ .Body }}</textarea 52 > 53 </div> 54 </div> 55 {{ end }} 56{{ end }}