Offer to remove WIP: prefix in sidebar
Fixes https://codeberg.org/forgejo/forgejo/issues/2654
This commit is contained in:
parent
fbdda5d5b0
commit
008706a438
2 changed files with 7 additions and 2 deletions
|
@ -1798,6 +1798,7 @@ pulls.title_wip_desc = `<a href="#">Start the title with <strong>%s</strong></a>
|
|||
pulls.cannot_merge_work_in_progress = This pull request is marked as a work in progress.
|
||||
pulls.still_in_progress = Still in progress?
|
||||
pulls.add_prefix = Add <strong>%s</strong> prefix
|
||||
pulls.ready_for_review = Ready for review?
|
||||
pulls.remove_prefix = Remove <strong>%s</strong> prefix
|
||||
pulls.data_broken = This pull request is broken due to missing fork information.
|
||||
pulls.files_conflicted = This pull request has changes conflicting with the target branch.
|
||||
|
|
|
@ -113,10 +113,14 @@
|
|||
{{end}}
|
||||
</div>
|
||||
</div>
|
||||
{{if and (or .HasIssuesOrPullsWritePermission .IsIssuePoster) (not .HasMerged) (not .Issue.IsClosed) (not .IsPullWorkInProgress)}}
|
||||
{{if and (or .HasIssuesOrPullsWritePermission .IsIssuePoster) (not .HasMerged) (not .Issue.IsClosed)}}
|
||||
<div class="toggle-wip" data-title="{{.Issue.Title}}" data-wip-prefix="{{index .PullRequestWorkInProgressPrefixes 0}}" data-update-url="{{.Issue.Link}}/title">
|
||||
<a class="muted">
|
||||
{{if .IsPullWorkInProgress}}
|
||||
{{ctx.Locale.Tr "repo.pulls.ready_for_review"}} {{ctx.Locale.Tr "repo.pulls.remove_prefix" (index .PullRequestWorkInProgressPrefixes 0)}}
|
||||
{{else}}
|
||||
{{ctx.Locale.Tr "repo.pulls.still_in_progress"}} {{ctx.Locale.Tr "repo.pulls.add_prefix" (index .PullRequestWorkInProgressPrefixes 0)}}
|
||||
{{end}}
|
||||
</a>
|
||||
</div>
|
||||
{{end}}
|
||||
|
|
Loading…
Reference in a new issue