From f8b85d4b4e1f830b473b06d42a380659355485e3 Mon Sep 17 00:00:00 2001 From: miloschwartz Date: Fri, 1 May 2026 16:13:54 -0700 Subject: [PATCH] fix sidebar product updates spacing --- src/components/ProductUpdates.tsx | 83 +++++++++++++++++-------------- 1 file changed, 47 insertions(+), 36 deletions(-) diff --git a/src/components/ProductUpdates.tsx b/src/components/ProductUpdates.tsx index b1da32a93..0d88853a7 100644 --- a/src/components/ProductUpdates.tsx +++ b/src/components/ProductUpdates.tsx @@ -81,10 +81,10 @@ export default function ProductUpdates({ const showNewVersionPopup = Boolean( latestVersion && - valid(latestVersion) && - valid(currentVersion) && - ignoredVersionUpdate !== latestVersion && - gt(latestVersion, currentVersion) + valid(latestVersion) && + valid(currentVersion) && + ignoredVersionUpdate !== latestVersion && + gt(latestVersion, currentVersion) ); const filteredUpdates = data.updates.filter( @@ -103,40 +103,51 @@ export default function ProductUpdates({ )} >
- {filteredUpdates.length > 1 && ( - 0 && ( +
+ {filteredUpdates.length > 1 && ( + + + + {showNewVersionPopup + ? t("productUpdateMoreInfo", { + noOfUpdates: + filteredUpdates.length + }) + : t("productUpdateInfo", { + noOfUpdates: + filteredUpdates.length + })} + + )} - > - - - {showNewVersionPopup - ? t("productUpdateMoreInfo", { - noOfUpdates: filteredUpdates.length - }) - : t("productUpdateInfo", { - noOfUpdates: filteredUpdates.length - })} - - + 0} + onDimissAll={() => + setProductUpdatesRead([ + ...productUpdatesRead, + ...filteredUpdates.map( + (update) => update.id + ) + ]) + } + onDimiss={(id) => + setProductUpdatesRead([ + ...productUpdatesRead, + id + ]) + } + /> +
)} - 0} - onDimissAll={() => - setProductUpdatesRead([ - ...productUpdatesRead, - ...filteredUpdates.map((update) => update.id) - ]) - } - onDimiss={(id) => - setProductUpdatesRead([...productUpdatesRead, id]) - } - />