fix(web): fix card height mismatch caused by long device names with dedicated row and ellipsis

This commit is contained in:
kory
2026-09-28 09:49:13 +08:00
parent 80db7a482a
commit c11aadaa68
4 changed files with 30 additions and 22 deletions
+5 -3
View File
@@ -48,14 +48,16 @@ async function loadDevices(){
return `
<div class="device-card ${isOnline ? "online" : "offline"}">
<div class="device-head">
<div class="device-title">
<div class="device-topbar">
<div class="device-status-wrap">
<span class="dot"></span>
<strong class="device-name">${esc(d.name)}</strong>
<span class="role-badge role-${role.toLowerCase()}">${esc(role)}</span>
</div>
<button class="btn-revoke" onclick="removeDevice('${esc(d.name)}')">注销</button>
</div>
<div class="device-name-row">
<strong class="device-name" title="${esc(d.name)}">${esc(d.name)}</strong>
</div>
<div class="device-meta">
<span>${esc(d.status)}</span> ·
<span>${esc(d.arch||"")}/${esc(d.os||"")}</span>