This is the first step (the hardest part): * repo file list last commit message lazy load * admin server status monitor * watch/unwatch (normal page, watchers page) * star/unstar (normal page, watchers page) * project view, delete column * workflow dispatch, switch the branch * commit page: load branches and tags referencing this commit The legacy "data-redirect" attribute is removed, it only makes the page reload (sometimes using an incorrect link). Also did cleanup for some devtest pages.
56 lines
2.7 KiB
Handlebars
56 lines
2.7 KiB
Handlebars
<div class="ui blue info attached message tw-relative tw-z-10 tw-flex tw-justify-between tw-items-center">
|
|
<span class="ui text middle">{{ctx.Locale.Tr "actions.workflow.has_workflow_dispatch"}}</span>
|
|
<button class="ui mini button show-modal" data-modal="#runWorkflowDispatchModal">{{ctx.Locale.Tr "actions.workflow.run"}}{{svg "octicon-triangle-down" 14 "dropdown icon"}}</button>
|
|
</div>
|
|
<div id="runWorkflowDispatchModal" class="ui tiny modal">
|
|
<div class="content">
|
|
<form id="runWorkflowDispatchForm" class="ui form ignore-dirty" action="{{$.Link}}/run?workflow={{$.CurWorkflow}}&actor={{$.CurActor}}&status={{.Status}}" method="post">
|
|
<div class="ui inline field required tw-flex tw-items-center">
|
|
<span class="ui inline required field">
|
|
<label>{{ctx.Locale.Tr "actions.workflow.from_ref"}}:</label>
|
|
</span>
|
|
<div class="ui inline field dropdown button select-branch branch-selector-dropdown ellipsis-text-items">
|
|
<input type="hidden" name="ref" value="refs/heads/{{index .Branches 0}}"
|
|
data-fetch-trigger="change" data-fetch-sync="$body #runWorkflowDispatchModalInputs"
|
|
data-fetch-url="{{$.Link}}/workflow-dispatch-inputs?workflow={{$.CurWorkflow}}"
|
|
>
|
|
{{svg "octicon-git-branch" 14}}
|
|
<div class="default text">{{index .Branches 0}}</div>
|
|
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
|
|
<div class="menu transition">
|
|
<div class="ui icon search input">
|
|
<i class="icon">{{svg "octicon-filter" 16}}</i>
|
|
<input name="search" type="text" placeholder="{{ctx.Locale.Tr "repo.filter_branch_and_tag"}}...">
|
|
</div>
|
|
<div class="branch-tag-tab">
|
|
<a class="branch-tag-item reference column muted active" href="#" data-target="#branch-list">
|
|
{{svg "octicon-git-branch" 16 "tw-mr-1"}} {{ctx.Locale.Tr "repo.branches"}}
|
|
</a>
|
|
<a class="branch-tag-item reference column muted" href="#" data-target="#tag-list">
|
|
{{svg "octicon-tag" 16 "tw-mr-1"}} {{ctx.Locale.Tr "repo.tags"}}
|
|
</a>
|
|
</div>
|
|
<div class="branch-tag-divider"></div>
|
|
<div id="branch-list" class="scrolling menu reference-list-menu">
|
|
{{range .Branches}}
|
|
<div class="item" data-value="refs/heads/{{.}}" title="{{.}}">{{.}}</div>
|
|
{{else}}
|
|
<div class="item">{{ctx.Locale.Tr "no_results_found"}}</div>
|
|
{{end}}
|
|
</div>
|
|
<div id="tag-list" class="scrolling menu reference-list-menu tw-hidden">
|
|
{{range .Tags}}
|
|
<div class="item" data-value="refs/tags/{{.}}" title="{{.}}">{{.}}</div>
|
|
{{else}}
|
|
<div class="item">{{ctx.Locale.Tr "no_results_found"}}</div>
|
|
{{end}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="divider"></div>
|
|
{{template "repo/actions/workflow_dispatch_inputs" .}}
|
|
</form>
|
|
</div>
|
|
</div>
|