fix(desktop): hide more when limit is not exceeded for entry read history

This commit is contained in:
Stephen Zhou 2025-05-21 09:26:54 +08:00
parent 6be20f483c
commit 04583a3003
No known key found for this signature in database
1 changed files with 13 additions and 11 deletions

View File

@ -64,17 +64,19 @@ export const EntryReadHistory: Component<{ entryId: string }> = ({ entryId }) =>
))}
</AvatarGroup>
<div
style={{
margin: "-8px",
zIndex: LIMIT + 1,
}}
className="no-drag-region border-border bg-material-opaque ring-background relative flex size-7 items-center justify-center rounded-full border ring-2"
>
<span className="text-text-secondary text-[10px] font-medium tabular-nums">
+{Math.min(totalCount - LIMIT, 99)}
</span>
</div>
{totalCount > LIMIT && (
<div
style={{
margin: "-8px",
zIndex: LIMIT + 1,
}}
className="no-drag-region border-border bg-material-opaque ring-background relative flex size-7 items-center justify-center rounded-full border ring-2"
>
<span className="text-text-secondary text-[10px] font-medium tabular-nums">
+{Math.min(totalCount - LIMIT, 99)}
</span>
</div>
)}
</div>
)
}