style: icon buttons inline with name

This commit is contained in:
tian 2026-05-08 11:38:35 +08:00
parent b64db6b0f0
commit f3716e1a7d

View File

@ -32,13 +32,13 @@
<div class="muted" style="display:flex;align-items:center;justify-content:center;height:100%">无照片</div>
{{end}}
</div>
<div style="margin-top:6px">
<div style="font-weight:500;font-size:13px">{{.Name}} <span class="muted small">{{.PhotoCount}}张</span></div>
<div class="actions compact" style="margin-top:4px">
<button class="btn ghost" type="button" style="font-size:11px;padding:2px 6px" onclick="showEdit({{.ID}},'{{.Name}}',[{{range $i,$p := .Photos}}{{if $i}},{{end}}'/ui/face-photo/{{$p}}'{{end}}])">编辑</button>
<div style="margin-top:6px;display:flex;justify-content:space-between;align-items:center">
<div><span style="font-weight:500;font-size:13px">{{.Name}}</span> <span class="muted small">{{.PhotoCount}}张</span></div>
<div class="actions compact" style="gap:2px">
<button class="btn ghost" type="button" style="font-size:11px;padding:2px 4px" title="编辑" onclick="showEdit({{.ID}},'{{.Name}}',[{{range $i,$p := .Photos}}{{if $i}},{{end}}'/ui/face-photo/{{$p}}'{{end}}])">&#9998;</button>
<form method="post" action="/ui/face-gallery/delete" style="display:inline" onsubmit="return confirm('确定删除 {{.Name}}')">
<input type="hidden" name="id" value="{{.ID}}">
<button class="btn ghost" type="submit" style="color:var(--danger-soft-text);font-size:11px;padding:2px 6px">删除</button>
<button class="btn ghost" type="submit" style="color:var(--danger-soft-text);font-size:11px;padding:2px 4px" title="删除">&#10005;</button>
</form>
</div>
</div>