From f521e88240a2d5dd41ee42d78b96fc89309f1790 Mon Sep 17 00:00:00 2001 From: Hester Gong Date: Mon, 13 Mar 2023 13:31:06 +0800 Subject: Fix actions frontend bugs (pagination, long name alignment) and small simplify (#23370) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1 Right now on actions page, the action list will not be aligned if commit message is long. In this PR, the changes are: - The branch tag is moved to bottom row - Width percentage is given to make them aligned - Show "..." if commit is longer than two lines. - Align the status icon with the commit message with baseline Before: 截屏2023-03-08 12 23 22 After: 截屏2023-03-08 13 34 28 2 Right now the actions list's pagination is not working properly because Param is not passed to pagination template, in this PR Param Strings are passed to the pager Before: 截屏2023-03-08 12 23 50 After: 截屏2023-03-08 13 11 54 3 A small simplify in `RepoActionView.vue` . --------- Co-authored-by: wxiaoguang Co-authored-by: Lunny Xiao --- templates/repo/actions/runs_list.tmpl | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'templates/repo/actions') diff --git a/templates/repo/actions/runs_list.tmpl b/templates/repo/actions/runs_list.tmpl index ffabe534c8..a28b9d7137 100644 --- a/templates/repo/actions/runs_list.tmpl +++ b/templates/repo/actions/runs_list.tmpl @@ -1,14 +1,18 @@
{{range .Runs}} -
  • +
  • {{template "repo/actions/status" .Status}}
    -
    +
    +
    + {{if not $.CurWorkflow}}{{.WorkflowID}} {{end}}#{{.Index}}: {{$.locale.Tr "actions.runs.commit"}} + {{ShortSha .CommitSHA}}{{$.locale.Tr "actions.runs.pushed_by"}} {{.TriggerUser.GetDisplayName}} {{if .RefLink}} {{.PrettyRef}} @@ -17,10 +21,6 @@ {{end}}
    -
    - {{if not $.CurWorkflow}}{{.WorkflowID}} {{end}}#{{.Index}}: {{$.locale.Tr "actions.runs.commit"}} - {{ShortSha .CommitSHA}}  {{$.locale.Tr "actions.runs.pushed_by"}} {{.TriggerUser.GetDisplayName | Escape}} -
    {{TimeSinceUnix .Updated $.locale}}
    -- cgit v1.2.3