From 8dbd7003d3261d6a229ddfe627cb0bbd6bef217c Mon Sep 17 00:00:00 2001 From: Stephen Zhou <38493346+hyoban@users.noreply.github.com> Date: Wed, 25 Dec 2024 22:05:27 +0800 Subject: [PATCH] fix: update --- .../entry-column/templates/list-item-template.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/renderer/src/modules/entry-column/templates/list-item-template.tsx b/apps/renderer/src/modules/entry-column/templates/list-item-template.tsx index d3c7f04ab..937b15c3c 100644 --- a/apps/renderer/src/modules/entry-column/templates/list-item-template.tsx +++ b/apps/renderer/src/modules/entry-column/templates/list-item-template.tsx @@ -88,12 +88,13 @@ export function ListItem({ const hasAudio = entry.entries?.attachments?.[0].url const hasMedia = entry.entries?.media?.[0]?.url + const marginWidth = 8 * (isMobile ? 1.125 : 1) // calculate the max width to have a correct truncation // FIXME: this is not easy to maintain, need to refactor - const feedIconWidth = 20 + 8 * (isMobile ? 1.125 : 1) - const audioCoverWidth = settingWideMode ? 65 : 80 - const mediaWidth = - (settingWideMode ? 48 : 80) * (isMobile ? 1.125 : 1) + 8 * (isMobile ? 1.125 : 1) + const feedIconWidth = 20 + marginWidth + const audioCoverWidth = settingWideMode ? 65 : 80 + marginWidth + const mediaWidth = (settingWideMode ? 48 : 80) * (isMobile ? 1.125 : 1) + marginWidth + let savedWidth = 0 if (!withAudio) { savedWidth += feedIconWidth