Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/vole.git

Write over SSH with a registered key:

git clone ssh://git@rodent.software:2222/vole.git

A free and open-source forge that lives in your Git repo.

Build out change review and threaded discussions

f6f4b1db24292d1df877680714952a9c568e2b78 · Keenan Nemetz · 15d ago · parent 564acd4b

Build out change review and threaded discussions

- Add Conversation, Files and Runs tabs to change requests. Files uses the
  code-browser shape with a changed-file tree and one selected-file diff;
  Runs lists the head commit's workflow results.
- Show anchored review comments beneath the line, with a collapsed excerpt
  read from the exact blob that was reviewed, and return posted anchors to
  their line note.
- Add comment threads: any comment can be replied to, the UI flattens the
  descendants under one root, reply context links back to the parent, and
  reply targets feed a single composer at the foot of the discussion.
- Collapse reply groups while keeping the root visible, and scroll to the
  composer when Reply is selected.
- Add comment context menus with Reply, Copy text, Copy link, Edit and
  Delete. Add web edit/delete routes with author or admin checks; deletion
  leaves a tombstone so replies keep their thread.
- Support --reply-to in the issue and change CLI commands, and treat a
  missing parent as a tombstone rather than an invalid tree.
- Fix the diff comment gutter, action button colours, reply labels, and
  keep the Files tree and diff pane aligned.

Update metadata validation, web templates, CSS, JavaScript, tests, and the
CLI/change-request/issue docs.

server/web/templates/layout.html +17−3

@@ -104,6 +104,7 @@
104 104 {{end}}
105 105 {{if .Hunks}}
106 106 <table>
107 <colgroup><col class="comment-col"><col class="ln-col"><col class="ln-col"><col></colgroup>
107 108 <tbody>
108 109 {{range .Hunks}}
109 110 <tr class="hunk"><td colspan="4">{{.Header}}</td></tr>
@@ -111,14 +112,27 @@
111 112 {{$side := "new"}}{{$path := $file.NewPath}}
112 113 {{if eq .Kind "del"}}{{$side = "old"}}{{$path = $file.OldPath}}{{end}}
113 114 <tr class="{{.Kind}}">
114 <td class="comment">
115 {{if and $.LineCommentURL $path}}<a href="{{$.LineCommentURL}}?path={{urlquery $path}}&amp;line={{if eq $side "old"}}{{.OldNo}}{{else}}{{.NewNo}}{{end}}&amp;side={{$side}}#request-comment-form" title="Comment on this line" aria-label="Comment on this line">{{icon "plus"}}</a>{{end}}
115 <td class="comment-cell">
116 {{if and $.LineCommentURL $path}}<a href="{{$.LineCommentURL}}?path={{urlquery $path}}&amp;line={{if eq $side "old"}}{{.OldNo}}{{else}}{{.NewNo}}{{end}}&amp;side={{$side}}#request-comment-form" hx-get="{{$.LineCommentURL}}/comment-form?path={{urlquery $path}}&amp;line={{if eq $side "old"}}{{.OldNo}}{{else}}{{.NewNo}}{{end}}&amp;side={{$side}}" hx-target="closest tr" hx-swap="afterend" data-inline-comment-add title="Comment on this line" aria-label="Comment on this line">{{icon "plus"}}</a>{{end}}
116 117 </td>
117 118 <td class="ln">{{if .OldNo}}{{.OldNo}}{{end}}</td>
118 119 <td class="ln">{{if .NewNo}}{{.NewNo}}{{end}}</td>
119 120 <td class="code">{{.Text}}</td>
120 121 </tr>
121 {{if .Comments}}<tr class="note"><td colspan="4">{{range .Comments}}<a class="label" href="#c-{{.ID}}">{{who .Author}} commented</a>{{end}}</td></tr>{{end}}
122 {{if .Comments}}
123 <tr class="note"><td colspan="4">
124 {{range .Comments}}
125 <div class="inline-note" id="inline-c-{{.ID}}">
126 <div class="inline-note-head">
127 <span class="avatar c{{tone .Author}}" aria-hidden="true">{{initial (who .Author)}}</span>
128 <a class="comment-author" href="#c-{{.ID}}">{{who .Author}}</a>
129 <span class="muted">{{since .Created.Unix}}</span>
130 </div>
131 <div class="comment-body md">{{.Body}}</div>
132 </div>
133 {{end}}
134 </td></tr>
135 {{end}}
122 136 {{end}}
123 137 {{end}}
124 138 </tbody>