forked from tangled.org/core
this repo has no description

appview: fix crash when setting description of forked repo

Signed-off-by: oppiliappan <me@oppi.li>

oppi.li 178c2851 a96b5173

verified
Changed files
+8 -8
appview
pages
templates
layouts
fragments
notifications
fragments
repo
+1 -1
appview/pages/templates/layouts/fragments/topbar.html
··· 7 7 </a> 8 8 </div> 9 9 10 - <div id="right-items" class="flex items-center gap-2"> 10 + <div id="right-items" class="flex items-center gap-4"> 11 11 {{ with .LoggedInUser }} 12 12 {{ block "newButton" . }} {{ end }} 13 13 {{ template "notifications/fragments/bell" }}
+1 -1
appview/pages/templates/notifications/fragments/bell.html
··· 3 3 hx-get="/notifications/count" 4 4 hx-target="#notification-count" 5 5 hx-trigger="load, every 30s"> 6 - <a href="/notifications" class="text-gray-500 dark:text-gray-400 flex gap-1 items-center group ml-4 mr-2"> 6 + <a href="/notifications" class="text-gray-500 dark:text-gray-400 flex gap-1 items-end group"> 7 7 {{ i "bell" "w-5 h-5" }} 8 8 <span id="notification-count"></span> 9 9 </a>
+5 -5
appview/pages/templates/notifications/fragments/count.html
··· 1 1 {{define "notifications/fragments/count"}} 2 - {{if and .Count (gt .Count 0)}} 3 - <span class="absolute -top-1 -right-0.5 min-w-[16px] h-[16px] px-1 bg-red-500 text-white text-xs font-medium rounded-full flex items-center justify-center"> 4 - {{if gt .Count 99}}99+{{else}}{{.Count}}{{end}} 5 - </span> 6 - {{end}} 2 + {{if and .Count (gt .Count 0)}} 3 + <span class="absolute -top-1.5 -right-0.5 min-w-[16px] h-[16px] px-1 bg-red-500 text-white text-xs font-medium rounded-full flex items-center justify-center"> 4 + {{if gt .Count 99}}99+{{else}}{{.Count}}{{end}} 5 + </span> 6 + {{end}} 7 7 {{end}}
+1 -1
appview/repo/repo.go
··· 2189 2189 Knot: targetKnot, 2190 2190 Rkey: rkey, 2191 2191 Source: sourceAt, 2192 - Description: existingRepo.Description, 2192 + Description: f.Repo.Description, 2193 2193 Created: time.Now(), 2194 2194 Labels: models.DefaultLabelDefs(), 2195 2195 }