feat: update gitea vendor
runner nix smoke / nix label and flake smoke (push) Failing after 1m28s

This commit is contained in:
2026-09-26 21:18:24 +00:00
parent c439c1b948
commit d9b2a4e787
3538 changed files with 116131 additions and 44340 deletions
@@ -1,4 +1,8 @@
{{template "base/head" .}}
{{$showCreateWorkflowBadge := Iif .WorkflowBadge true false}}
{{$showEnableDisableWorkflow := and .AllowDisableOrEnableWorkflow .CurWorkflowIsListed $.CurWorkflow}}
<div class="page-content repository actions">
{{template "repo/header" .}}
<div class="ui container">
@@ -7,25 +11,60 @@
{{if .HasWorkflowsOrRuns}}
<div class="flex-container">
<div class="flex-container-nav">
<div class="ui fluid vertical menu flex-items-block">
<a class="item {{if not $.CurWorkflow}}active{{end}}" href="?actor={{$.CurActor}}&status={{$.CurStatus}}">{{ctx.Locale.Tr "actions.runs.all_workflows"}}</a>
<div class="ui fluid vertical menu">
<a class="item {{if not $.CurWorkflow}}active{{end}}" href="?actor={{$.CurActor}}&status={{$.CurStatus}}&branch={{$.CurBranch}}">{{ctx.Locale.Tr "actions.runs.all_workflows"}}</a>
{{range .workflows}}
<a class="item {{if eq .Entry.Name $.CurWorkflow}}active{{end}}" href="?workflow={{.Entry.Name}}&actor={{$.CurActor}}&status={{$.CurStatus}}">
<span class="gt-ellipsis">{{.Entry.Name}}</span>
<a class="item flex-text-block {{if and (eq .Entry.Name $.CurWorkflow) (not $.CurWorkflowScopedRepoID)}}active{{end}}" href="?workflow={{.Entry.Name}}&actor={{$.CurActor}}&status={{$.CurStatus}}&branch={{$.CurBranch}}">
<span class="gt-ellipsis" data-tooltip-content="{{.DisplayName}}">{{.DisplayName}}</span>
{{if .ErrMsg}}
<span class="flex-text-inline" data-tooltip-content="{{.ErrMsg}}">{{svg "octicon-alert" 16 "tw-text-red"}}</span>
<span class="flex-text-inline tw-shrink-0" data-tooltip-content="{{.ErrMsg}}">{{svg "octicon-alert" 16 "tw-text-red"}}</span>
{{end}}
{{if $.ActionsConfig.IsWorkflowDisabled .Entry.Name}}
<div class="ui red label">{{ctx.Locale.Tr "disabled"}}</div>
<div class="ui red label tw-shrink-0">{{ctx.Locale.Tr "disabled"}}</div>
{{end}}
</a>
{{end}}
{{range .ScopedWorkflowGroups}}
<details class="item scoped-workflow-group"{{if .IsActive}} open{{end}}>
<summary>
<span class="gt-ellipsis tw-min-w-0" data-tooltip-content="{{.SourceRepoName}}">{{if .FromInstance}}{{.SourceRepoName}}{{else}}{{.SourceRepoShortName}}{{end}}</span>
<span class="ui label">{{if .FromInstance}}{{ctx.Locale.Tr "actions.workflow.scope_global"}}{{else}}{{ctx.Locale.Tr "actions.workflow.scope_owner"}}{{end}}</span>
</summary>
{{range .Workflows}}
<a class="item flex-text-block {{if and (eq .EntryName $.CurWorkflow) (eq .SourceRepoID $.CurWorkflowScopedRepoID)}}active{{end}}" href="?workflow={{.EntryName}}&scoped_workflow_source_repo_id={{.SourceRepoID}}&actor={{$.CurActor}}&status={{$.CurStatus}}&branch={{$.CurBranch}}">
<span class="gt-ellipsis tw-min-w-0" data-tooltip-content="{{.EntryName}}">{{.DisplayName}}</span>
{{if .Required}}
<span class="ui label">{{ctx.Locale.Tr "actions.workflow.required"}}</span>
{{else if .Disabled}}
<span class="ui red label">{{ctx.Locale.Tr "disabled"}}</span>
{{end}}
</a>
{{end}}
</details>
{{end}}
{{if .OtherWorkflows}}
<details class="item"{{if not $.CurWorkflowIsListed}} open{{end}}>
<summary data-tooltip-content="{{ctx.Locale.Tr "actions.runs.other_workflows_tooltip"}}">
<span class="flex-text-block">
{{ctx.Locale.Tr "actions.runs.other_workflows"}}
<span class="ui label">{{len .OtherWorkflows}}</span>
</span>
</summary>
<div class="menu items-full-width">
{{range .OtherWorkflows}}
<a class="item {{if eq . $.CurWorkflow}}active{{end}}" href="?workflow={{.}}&actor={{$.CurActor}}&status={{$.CurStatus}}">
<span class="gt-ellipsis" data-tooltip-content="{{.}}">{{.}}</span>
</a>
{{end}}
</div>
</details>
{{end}}
</div>
</div>
<div class="flex-container-main">
<div class="ui top attached header flex-text-block tw-flex-wrap tw-justify-between">
<div class="ui top attached header flex-left-right">
<strong>{{ctx.Locale.TrN .Page.Paginater.Total "actions.runs.workflow_run_count_1" "actions.runs.workflow_run_count_n" .Page.Paginater.Total}}</strong>
<div class="ui secondary filter menu flex-text-block tw-m-0">
<!-- Actor -->
@@ -37,11 +76,11 @@
<i class="icon">{{svg "octicon-search"}}</i>
<input type="text" placeholder="{{ctx.Locale.Tr "actions.runs.actor"}}">
</div>
<a class="item{{if not $.CurActor}} active{{end}}" href="?workflow={{$.CurWorkflow}}&status={{$.CurStatus}}&actor=0">
<a class="item{{if not $.CurActor}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&status={{$.CurStatus}}&branch={{$.CurBranch}}&actor=0">
{{ctx.Locale.Tr "actions.runs.actors_no_select"}}
</a>
{{range .Actors}}
<a class="item{{if eq .ID $.CurActor}} active{{end}}" href="?workflow={{$.CurWorkflow}}&actor={{.ID}}&status={{$.CurStatus}}">
<a class="item{{if eq .ID $.CurActor}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{.ID}}&status={{$.CurStatus}}&branch={{$.CurBranch}}">
{{ctx.AvatarUtils.Avatar . 20}} {{.GetDisplayName}}
</a>
{{end}}
@@ -56,24 +95,53 @@
<i class="icon">{{svg "octicon-search"}}</i>
<input type="text" placeholder="{{ctx.Locale.Tr "actions.runs.status"}}">
</div>
<a class="item{{if not $.CurStatus}} active{{end}}" href="?workflow={{$.CurWorkflow}}&actor={{$.CurActor}}&status=0">
<a class="item{{if not $.CurStatus}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{$.CurActor}}&branch={{$.CurBranch}}&status=0">
{{ctx.Locale.Tr "actions.runs.status_no_select"}}
</a>
{{range .StatusInfoList}}
<a class="item{{if eq .Status $.CurStatus}} active{{end}}" href="?workflow={{$.CurWorkflow}}&actor={{$.CurActor}}&status={{.Status}}">
{{.DisplayedStatus}}
<a class="item{{if eq .Status $.CurStatus}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{$.CurActor}}&status={{.Status}}&branch={{$.CurBranch}}">
<span class="flex-text-inline tw-gap-2">
{{template "repo/icons/action_status" (dict "Status" .StatusName)}}
{{.DisplayedStatus}}
</span>
</a>
{{end}}
</div>
</div>
<!-- Branch -->
<div class="ui{{if not .RunBranches}} disabled{{end}} dropdown jump item" data-test-id="filter-branch">
<span class="text">{{ctx.Locale.Tr "actions.runs.branch"}}</span>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
<div class="menu">
<div class="ui icon search input">
<i class="icon">{{svg "octicon-search"}}</i>
<input type="text" placeholder="{{ctx.Locale.Tr "actions.runs.branch"}}">
</div>
<a class="item{{if not $.CurBranch}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{$.CurActor}}&status={{$.CurStatus}}">
{{ctx.Locale.Tr "actions.runs.branches_no_select"}}
</a>
{{range .RunBranches}}
<a class="item{{if eq . $.CurBranch}} selected{{end}}" href="?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{$.CurActor}}&status={{$.CurStatus}}&branch={{.}}">
{{.}}
</a>
{{end}}
</div>
</div>
{{if .AllowDisableOrEnableWorkflow}}
{{if or $showCreateWorkflowBadge $showEnableDisableWorkflow}}
<button class="ui jump dropdown btn interact-bg tw-p-2">
{{svg "octicon-kebab-horizontal"}}
<div class="menu">
<a class="item link-action" data-url="{{$.Link}}/{{if .CurWorkflowDisabled}}enable{{else}}disable{{end}}?workflow={{$.CurWorkflow}}&actor={{.CurActor}}&status={{$.CurStatus}}">
{{if .CurWorkflowDisabled}}{{ctx.Locale.Tr "actions.workflow.enable"}}{{else}}{{ctx.Locale.Tr "actions.workflow.disable"}}{{end}}
{{if $showCreateWorkflowBadge}}
<div class="item show-modal" data-modal="#workflow-status-badge-modal">
{{ctx.Locale.Tr "actions.workflow.create_status_badge"}}
</div>
{{end}}
{{if $showEnableDisableWorkflow}}
<a class="item {{if .CurWorkflowRequired}}disabled{{else}}link-action{{end}}"{{if not .CurWorkflowRequired}} data-url="{{$.Link}}/{{if .CurWorkflowDisabled}}enable{{else}}disable{{end}}?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{.CurActor}}&status={{$.CurStatus}}&branch={{$.CurBranch}}"{{end}}>
{{if .CurWorkflowRequired}}{{ctx.Locale.Tr "actions.workflow.disable"}}{{else if .CurWorkflowDisabled}}{{ctx.Locale.Tr "actions.workflow.enable"}}{{else}}{{ctx.Locale.Tr "actions.workflow.disable"}}{{end}}
</a>
{{end}}
</div>
</button>
{{end}}
@@ -94,4 +162,53 @@
{{end}}
</div>
</div>
{{if $showCreateWorkflowBadge}}
<div id="workflow-status-badge-modal" class="ui tiny modal">
<div class="header">{{ctx.Locale.Tr "actions.workflow.status_badge"}}</div>
<div class="content">
<div class="ui form" data-global-init="initWorkflowBadgeForm"
data-badge-url="{{.WorkflowBadge.BadgeURL}}"
data-workflow-url="{{.WorkflowBadge.WorkflowURL}}"
data-workflow-display-name="{{.WorkflowBadge.DisplayName}}"
>
<div class="field">
<img data-workflow-badge-image src="{{.WorkflowBadge.BadgeURL}}" alt="{{.CurWorkflow}}">
</div>
<div class="field">
<label>{{ctx.Locale.Tr "actions.runs.branch"}}</label>
<div class="ui selection dropdown">
<input type="hidden" data-workflow-badge-branch value="{{.Repository.DefaultBranch}}">
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
<div class="text">{{.Repository.DefaultBranch}}</div>
<div class="menu">
<div class="item selected" data-value="{{.Repository.DefaultBranch}}">{{.Repository.DefaultBranch}}</div>
{{range $branchName := .RunBranches}}
{{if ne $branchName $.Repository.DefaultBranch}}
<div class="item" data-value="{{$branchName}}">{{$branchName}}</div>
{{end}}
{{end}}
</div>
</div>
</div>
<div class="field">
<label>{{ctx.Locale.Tr "actions.workflow.status_badge_url"}}</label>
<div class="ui action input">
<input id="workflow-badge-url" readonly autofocus>
<button class="ui icon button" data-tooltip-content="{{ctx.Locale.Tr "copy"}}" data-clipboard-target="#workflow-badge-url">{{svg "octicon-copy" 14}}</button>
</div>
</div>
<div class="field">
<label>Markdown</label>
<textarea id="workflow-badge-markdown" rows="2" readonly></textarea>
</div>
<div class="field">
<label>HTML</label>
<textarea id="workflow-badge-html" rows="2" readonly></textarea>
</div>
</div>
</div>
</div>
{{end}}
{{template "base/footer" .}}
@@ -1,4 +1,4 @@
<div class="flex-list run-list">
<div class="flex-divided-list items-with-main run-list">
{{if not .Runs}}
<div class="empty-placeholder">
{{svg "octicon-no-entry" 48}}
@@ -6,20 +6,20 @@
</div>
{{end}}
{{range $run := .Runs}}
<div class="flex-item tw-items-center">
<div class="flex-item-leading">
{{template "repo/actions/status" (dict "status" $run.Status.String)}}
</div>
<div class="flex-item-main">
<span class="flex-item-title" title="{{$run.Title}}">
{{if $run.Title}}
{{ctx.RenderUtils.RenderCommitMessageLinkSubject $run.Title $run.Link $.Repository}}
{{else}}
<a href="{{$run.Link}}">{{ctx.Locale.Tr "actions.runs.empty_commit_message"}}</a>
{{end}}
<div class="item tw-items-center">
<div class="item-leading">
<span data-tooltip-content="{{ctx.Locale.Tr (printf "actions.status.%s" $run.Status.String)}}">
{{template "repo/icons/action_status" (dict "Status" $run.Status.String "IconVariant" "circle-fill")}}
</span>
<div class="flex-item-body">
<span><b>{{if not $.CurWorkflow}}{{$run.WorkflowID}} {{end}}#{{$run.Index}}</b>:</span>
</div>
<div class="item-main">
<div class="item-title">
{{$title := or $run.Title (ctx.Locale.Tr "actions.runs.empty_commit_message")}}
{{ctx.RenderUtils.RenderCommitMessageLinkSubject $title $run.Link $.Repository}}
</div>
<div class="item-body">
{{$workflowName := index $.WorkflowNames $run.WorkflowID}}
<span><b>{{if not $.CurWorkflow}}{{if $workflowName}}{{$workflowName}}{{else}}{{$run.WorkflowID}}{{end}} {{end}}#{{$run.Index}}</b>:</span>
{{- if $run.ScheduleID -}}
{{ctx.Locale.Tr "actions.runs.scheduled"}}
@@ -38,7 +38,7 @@
{{end}}
</div>
</div>
<div class="flex-item-trailing">
<div class="run-list-item-trailing">
{{if $run.IsRefDeleted}}
<span class="ui label run-list-ref gt-ellipsis tw-line-through" data-tooltip-content="{{$run.RefTooltip}}">{{$run.PrettyRef}}</span>
{{else}}
@@ -1,23 +0,0 @@
<!-- This template should be kept the same as web_src/js/components/ActionRunStatus.vue
Please also update the vue file above if this template is modified.
action status accepted: success, skipped, waiting, blocked, running, failure, cancelled, unknown
-->
{{- $size := Iif .size .size 16 -}}
{{- $className := Iif .className .className "" -}}
<span data-tooltip-content="{{ctx.Locale.Tr (printf "actions.status.%s" .status)}}">
{{if eq .status "success"}}
{{svg "octicon-check-circle-fill" $size (printf "tw-text-green %s" $className)}}
{{else if eq .status "skipped"}}
{{svg "octicon-skip" $size (printf "tw-text-text-light %s" $className)}}
{{else if eq .status "cancelled"}}
{{svg "octicon-stop" $size (printf "tw-text-text-light %s" $className)}}
{{else if eq .status "waiting"}}
{{svg "octicon-circle" $size (printf "tw-text-text-light %s" $className)}}
{{else if eq .status "blocked"}}
{{svg "octicon-blocked" $size (printf "tw-text-yellow %s" $className)}}
{{else if eq .status "running"}}
{{svg "gitea-running" $size (printf "tw-text-yellow rotate-clockwise %s" $className)}}
{{else}}{{/*failure, unknown*/}}
{{svg "octicon-x-circle-fill" $size (printf "tw-text-red %s" $className)}}
{{end}}
</span>
@@ -3,9 +3,8 @@
<div class="page-content repository">
{{template "repo/header" .}}
{{template "repo/actions/view_component" (dict
"RunID" .RunID
"JobID" .JobID
"ActionsURL" .ActionsURL
"ActionsViewURL" .ActionsViewURL
)}}
</div>
@@ -1,26 +1,36 @@
<div id="repo-action-view"
data-run-id="{{.RunID}}"
<div id="repo-action-view"
data-job-id="{{.JobID}}"
data-actions-url="{{.ActionsURL}}"
data-actions-view-url="{{.ActionsViewURL}}"
data-locale-approve="{{ctx.Locale.Tr "repo.diff.review.approve"}}"
data-locale-cancel="{{ctx.Locale.Tr "actions.runs.cancel"}}"
data-locale-rerun="{{ctx.Locale.Tr "rerun"}}"
data-locale-rerun-all="{{ctx.Locale.Tr "rerun_all"}}"
data-locale-rerun-failed="{{ctx.Locale.Tr "rerun_failed"}}"
data-locale-latest="{{ctx.Locale.Tr "actions.runs.latest"}}"
data-locale-latest-attempt="{{ctx.Locale.Tr "actions.runs.latest_attempt"}}"
data-locale-attempt="{{ctx.Locale.Tr "actions.runs.attempt"}}"
data-locale-runs-scheduled="{{ctx.Locale.Tr "actions.runs.scheduled"}}"
data-locale-runs-commit="{{ctx.Locale.Tr "actions.runs.commit"}}"
data-locale-runs-pushed-by="{{ctx.Locale.Tr "actions.runs.pushed_by"}}"
data-locale-runs-workflow-graph="{{ctx.Locale.Tr "actions.runs.workflow_graph"}}"
data-locale-summary="{{ctx.Locale.Tr "actions.runs.summary"}}"
data-locale-all-jobs="{{ctx.Locale.Tr "actions.runs.all_jobs"}}"
data-locale-job-summaries="{{ctx.Locale.Tr "actions.runs.job_summaries"}}"
data-locale-expand-caller-jobs="{{ctx.Locale.Tr "actions.runs.expand_caller_jobs"}}"
data-locale-collapse-caller-jobs="{{ctx.Locale.Tr "actions.runs.collapse_caller_jobs"}}"
data-locale-triggered-via="{{ctx.Locale.Tr "actions.runs.triggered_via"}}"
data-locale-rerun-triggered="{{ctx.Locale.Tr "actions.runs.rerun_triggered"}}"
data-locale-back-to-pull-request="{{ctx.Locale.Tr "actions.runs.back_to_pull_request"}}"
data-locale-back-to-workflow="{{ctx.Locale.Tr "actions.runs.back_to_workflow"}}"
data-locale-status-label="{{ctx.Locale.Tr "actions.runs.status"}}"
data-locale-total-duration="{{ctx.Locale.Tr "actions.runs.total_duration"}}"
data-locale-run-details="{{ctx.Locale.Tr "actions.runs.run_details"}}"
data-locale-workflow-file="{{ctx.Locale.Tr "actions.runs.workflow_file"}}"
data-locale-workflow-file-no-permission="{{ctx.Locale.Tr "actions.runs.workflow_file_no_permission"}}"
data-locale-status-unknown="{{ctx.Locale.Tr "actions.status.unknown"}}"
data-locale-status-waiting="{{ctx.Locale.Tr "actions.status.waiting"}}"
data-locale-status-running="{{ctx.Locale.Tr "actions.status.running"}}"
data-locale-status-cancelling="{{ctx.Locale.Tr "actions.status.cancelling"}}"
data-locale-status-success="{{ctx.Locale.Tr "actions.status.success"}}"
data-locale-status-failure="{{ctx.Locale.Tr "actions.status.failure"}}"
data-locale-status-cancelled="{{ctx.Locale.Tr "actions.status.cancelled"}}"
@@ -28,12 +38,25 @@
data-locale-status-blocked="{{ctx.Locale.Tr "actions.status.blocked"}}"
data-locale-artifacts-title="{{ctx.Locale.Tr "artifacts"}}"
data-locale-artifact-expired="{{ctx.Locale.Tr "expired"}}"
data-locale-artifact-expires-at="{{ctx.Locale.Tr "artifact_expires_at"}}"
data-locale-artifact-expired-at="{{ctx.Locale.Tr "artifact_expired_at"}}"
data-locale-confirm-delete-artifact="{{ctx.Locale.Tr "confirm_delete_artifact"}}"
data-locale-show-timestamps="{{ctx.Locale.Tr "show_timestamps"}}"
data-locale-show-log-seconds="{{ctx.Locale.Tr "show_log_seconds"}}"
data-locale-show-full-screen="{{ctx.Locale.Tr "show_full_screen"}}"
data-locale-download-logs="{{ctx.Locale.Tr "download_logs"}}"
data-locale-copy-output="{{ctx.Locale.Tr "copy_output"}}"
data-locale-logs-always-auto-scroll="{{ctx.Locale.Tr "actions.logs.always_auto_scroll"}}"
data-locale-logs-always-expand-running="{{ctx.Locale.Tr "actions.logs.always_expand_running"}}"
data-locale-workflow-dependencies="{{ctx.Locale.Tr "actions.runs.workflow_dependencies"}}"
data-locale-graph-jobs-count-1="{{ctx.Locale.Tr "actions.runs.graph_jobs_count_1"}}"
data-locale-graph-jobs-count-n="{{ctx.Locale.Tr "actions.runs.graph_jobs_count_n"}}"
data-locale-graph-dependencies-count-1="{{ctx.Locale.Tr "actions.runs.graph_dependencies_count_1"}}"
data-locale-graph-dependencies-count-n="{{ctx.Locale.Tr "actions.runs.graph_dependencies_count_n"}}"
data-locale-graph-success-rate="{{ctx.Locale.Tr "actions.runs.graph_success_rate"}}"
data-locale-graph-zoom-in="{{ctx.Locale.Tr "actions.runs.graph_zoom_in"}}"
data-locale-graph-zoom-max="{{ctx.Locale.Tr "actions.runs.graph_zoom_max"}}"
data-locale-graph-zoom-out="{{ctx.Locale.Tr "actions.runs.graph_zoom_out"}}"
data-locale-graph-reset-view="{{ctx.Locale.Tr "actions.runs.graph_reset_view"}}"
>
</div>
@@ -1,5 +1,5 @@
{{/* "z-index" is used to maintain continuous attached styling and keep the colored border-bottom visible (pre-existing fomantic issue with negative margins) */}}
<div class="ui blue info attached message flex-text-block tw-flex-wrap tw-justify-between tw-z-1">
<div class="ui blue info attached message flex-left-right tw-z-1">
<span>{{ctx.Locale.Tr "actions.workflow.has_workflow_dispatch"}}</span>
<div class="flex-text-block tw-bg-box-body tw-rounded">{{/*make the button have correct hovered color */}}
<button class="ui mini button show-modal" data-modal="#runWorkflowDispatchModal">{{ctx.Locale.Tr "actions.workflow.run"}}{{svg "octicon-triangle-down" 14 "dropdown icon"}}</button>
@@ -7,13 +7,16 @@
</div>
<div id="runWorkflowDispatchModal" class="ui tiny modal">
<div class="content">
<form id="runWorkflowDispatchForm" class="ui form" action="{{$.Link}}/run?workflow={{$.CurWorkflow}}&actor={{$.CurActor}}&status={{.Status}}" method="post">
<form id="runWorkflowDispatchForm" class="ui form ignore-dirty" action="{{$.Link}}/run?workflow={{$.CurWorkflow}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}&actor={{$.CurActor}}&status={{$.CurStatus}}&branch={{$.CurBranch}}" 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" hx-sync="this:replace" hx-target="#runWorkflowDispatchModalInputs" hx-swap="innerHTML" hx-get="{{$.Link}}/workflow-dispatch-inputs?workflow={{$.CurWorkflow}}" hx-trigger="change" value="refs/heads/{{index .Branches 0}}">
<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}}&scoped_workflow_source_repo_id={{$.CurWorkflowRepoID}}"
>
{{svg "octicon-git-branch" 14}}
<div class="default text">{{index .Branches 0}}</div>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
@@ -48,12 +51,8 @@
</div>
</div>
</div>
<div class="divider"></div>
<div id="runWorkflowDispatchModalInputs">
{{template "repo/actions/workflow_dispatch_inputs" .}}
</div>
{{template "repo/actions/workflow_dispatch_inputs" .}}
</form>
</div>
</div>
@@ -1,3 +1,4 @@
<div id="runWorkflowDispatchModalInputs">
{{if not .WorkflowDispatchConfig}}
<div class="ui error message tw-block">{{/* using "ui message" in "ui form" needs to force to display */}}
{{if not .CurWorkflowExists}}
@@ -11,16 +12,14 @@
<div class="ui field {{if .Required}}required{{end}}">
{{if eq .Type "choice"}}
<label>{{or .Description .Name}}:</label>
{{/* htmx won't initialize the fomantic dropdown, so it is a standard "select" input */}}
<select class="ui selection dropdown" name="{{.Name}}">
{{range .Options}}
<option value="{{.}}" {{if eq $item.Default .}}selected{{end}}>{{.}}</option>
{{end}}
</select>
{{else if eq .Type "boolean"}}
{{/* htmx doesn't trigger our JS code to attach fomantic label to checkbox, so here we use standard checkbox */}}
<label class="tw-flex flex-text-inline">
<input type="checkbox" name="{{.Name}}" {{if eq .Default "true"}}checked{{end}}>
<input type="checkbox" name="{{.Name}}" {{if .IsDefaultTrue}}checked{{end}}>
{{or .Description .Name}}
</label>
{{else if eq .Type "number"}}
@@ -44,3 +43,4 @@
</div>
{{end}}
{{end}}
</div>