This repository has no description
1{{ define "repo/pulls/fragments/pullResubmit" }}
2 <div
3 id="resubmit-pull-card"
4 class="rounded relative border bg-amber-50 dark:bg-amber-900 border-amber-200 dark:border-amber-500 px-6 py-2">
5
6 <div class="flex items-center gap-2 text-amber-500 dark:text-amber-50">
7 {{ i "pencil" "w-4 h-4" }}
8 <span class="font-medium">Resubmit your patch</span>
9 </div>
10
11 <div class="mt-2 text-sm text-gray-700 dark:text-gray-200">
12 You can update this patch to address any reviews.
13 This will begin a new round of reviews,
14 but you'll still be able to view your previous submissions and feedback.
15 </div>
16
17 <div class="mt-4 flex flex-col">
18 <form
19 hx-post="/{{ .RepoInfo.FullName }}/pulls/{{ .Pull.PullId }}/resubmit"
20 hx-swap="none"
21 hx-include="this"
22 class="w-full flex flex-wrap gap-2"
23 hx-indicator="#resubmit-spinner"
24 >
25 <textarea
26 name="patch"
27 class="w-full p-2 mb-2"
28 placeholder="Paste your updated patch here."
29 rows="15"
30 >
31 {{.Pull.LatestPatch}}
32 </textarea>
33 <button
34 type="submit"
35 class="btn flex items-center gap-2"
36 {{ if or .Pull.State.IsClosed }}
37 disabled
38 {{ end }}
39 >
40 {{ i "rotate-ccw" "w-4 h-4" }}
41 <span>Resubmit</span>
42 <span id="resubmit-spinner" class="group">
43 {{ i "loader-circle" "w-4 h-4 animate-spin hidden group-[.htmx-request]:inline" }}
44 </span>
45 </button>
46 <button
47 type="button"
48 class="btn flex items-center gap-2"
49 hx-get="/{{ .RepoInfo.FullName }}/pulls/{{ .Pull.PullId }}/round/{{ .Pull.LastRoundNumber }}/actions"
50 hx-swap="outerHTML"
51 hx-target="#resubmit-pull-card"
52 hx-indicator="#cancel-resubmit-spinner"
53 >
54 {{ i "x" "w-4 h-4" }}
55 <span>Cancel</span>
56 <span id="cancel-resubmit-spinner" class="group">
57 {{ i "loader-circle" "w-4 h-4 animate-spin hidden group-[.htmx-request]:inline" }}
58 </span>
59 </button>
60 </form>
61
62 <div id="resubmit-error" class="error"></div>
63 <div id="resubmit-success" class="success"></div>
64 </div>
65 </div>
66{{ end }}