Skip to content

Commit ee17289

Browse files
GiteaBotwxiaoguang
andauthored
Fix issue card layout (#30800) (#30820)
Backport #30800 by wxiaoguang Fix #30788 Co-authored-by: wxiaoguang <[email protected]>
1 parent d793f25 commit ee17289

File tree

3 files changed

+19
-10
lines changed

3 files changed

+19
-10
lines changed

templates/repo/issue/card.tmpl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,13 @@
6262
</div>
6363

6464
{{if or .Labels .Assignees}}
65-
<div class="tw-flex tw-justify-between">
66-
<div class="labels-list tw-flex-1">
65+
<div class="issue-card-bottom">
66+
<div class="labels-list">
6767
{{range .Labels}}
6868
<a target="_blank" href="{{$.Issue.Repo.Link}}/issues?labels={{.ID}}">{{RenderLabel ctx ctx.Locale .}}</a>
6969
{{end}}
7070
</div>
71-
<div class="tw-flex tw-flex-wrap tw-content-start tw-gap-1">
71+
<div class="issue-card-assignees">
7272
{{range .Assignees}}
7373
<a target="_blank" href="{{.HomeLink}}" data-tooltip-content="{{ctx.Locale.Tr "repo.projects.column.assigned_to"}} {{.Name}}">{{ctx.AvatarUtils.Avatar . 28}}</a>
7474
{{end}}

web_src/css/repo.css

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2195,18 +2195,12 @@ td .commit-summary {
21952195
display: inline-flex;
21962196
flex-wrap: wrap;
21972197
gap: 2.5px;
2198-
}
2199-
2200-
.labels-list a {
2201-
display: flex;
2202-
text-decoration: none;
2198+
align-items: center;
22032199
}
22042200

22052201
.labels-list .label {
22062202
padding: 0 6px;
2207-
margin: 0 !important;
22082203
min-height: 20px;
2209-
display: inline-flex !important;
22102204
line-height: 1.3; /* there is a `font-size: 1.25em` for inside emoji, so here the line-height needs to be larger slightly */
22112205
}
22122206

web_src/css/repo/issue-card.css

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,18 @@
2323
.issue-card.sortable-chosen .issue-card-title {
2424
cursor: inherit;
2525
}
26+
27+
.issue-card-bottom {
28+
display: flex;
29+
width: 100%;
30+
justify-content: space-between;
31+
gap: 0.25em;
32+
}
33+
34+
.issue-card-assignees {
35+
display: flex;
36+
align-items: center;
37+
gap: 0.25em;
38+
justify-content: end;
39+
flex-wrap: wrap;
40+
}

0 commit comments

Comments
 (0)