mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-22 08:42:32 -05:00
099682892b
Add an empty hash `href="#"` attribute to anchors that did not yet have any `href` attribute, as a quick work-around to make those elements possible to interact with via keyboard. See discussion on linked issue (https://codeberg.org/forgejo/forgejo/issues/4273) for more information on how the button-like elements like this could eventually be improved even more. Fixes https://codeberg.org/forgejo/forgejo/issues/4273. Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/4375 Reviewed-by: Gusted <gusted@noreply.codeberg.org> Co-authored-by: banaanihillo <banaanihillo@noreply.codeberg.org> Co-committed-by: banaanihillo <banaanihillo@noreply.codeberg.org>
49 lines
2.3 KiB
Go HTML Template
49 lines
2.3 KiB
Go HTML Template
<div class="divider"></div>
|
|
<details class="collapsible">
|
|
<summary class="tw-py-2"> {{ctx.Locale.Tr "repo.pulls.cmd_instruction_hint"}} </summary>
|
|
<div><h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_checkout_title"}}</h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_checkout_desc"}}</div>
|
|
{{$localBranch := .PullRequest.HeadBranch}}
|
|
{{if ne .PullRequest.HeadRepo.ID .PullRequest.BaseRepo.ID}}
|
|
{{$localBranch = print .PullRequest.HeadRepo.OwnerName "-" .PullRequest.HeadBranch}}
|
|
{{end}}
|
|
<div class="ui secondary segment">
|
|
{{if eq .PullRequest.Flow 0}}
|
|
<div>git fetch -u {{if ne .PullRequest.HeadRepo.ID .PullRequest.BaseRepo.ID}}<origin-url data-url="{{.PullRequest.HeadRepo.Link}}"></origin-url>{{else}}origin{{end}} {{.PullRequest.HeadBranch}}:{{$localBranch}}</div>
|
|
<div>git checkout {{$localBranch}}</div>
|
|
{{else}}
|
|
<div>git fetch -u origin {{.GetGitRefName}}:{{$localBranch}}</div>
|
|
{{end}}
|
|
</div>
|
|
{{if .ShowMergeInstructions}}
|
|
<div><h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_merge_title"}}</h3>{{ctx.Locale.Tr "repo.pulls.cmd_instruction_merge_desc"}}</div>
|
|
<div class="ui secondary segment">
|
|
<div data-pull-merge-style="merge">
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge --no-ff {{$localBranch}}</div>
|
|
</div>
|
|
<div class="tw-hidden" data-pull-merge-style="rebase">
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge --ff-only {{$localBranch}}</div>
|
|
</div>
|
|
<div class="tw-hidden" data-pull-merge-style="rebase-merge">
|
|
<div>git checkout {{$localBranch}}</div>
|
|
<div>git rebase {{.PullRequest.BaseBranch}}</div>
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge --no-ff {{$localBranch}}</div>
|
|
</div>
|
|
<div class="tw-hidden" data-pull-merge-style="squash">
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge --squash {{$localBranch}}</div>
|
|
</div>
|
|
<div class="tw-hidden" data-pull-merge-style="fast-forward-only">
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge --ff-only {{$localBranch}}</div>
|
|
</div>
|
|
<div class="tw-hidden" data-pull-merge-style="manually-merged">
|
|
<div>git checkout {{.PullRequest.BaseBranch}}</div>
|
|
<div>git merge {{$localBranch}}</div>
|
|
</div>
|
|
<div>git push origin {{.PullRequest.BaseBranch}}</div>
|
|
</div>
|
|
{{end}}
|
|
</details>
|