From a42a19b087ecb994371769cf1ceae645cdcffb2f Mon Sep 17 00:00:00 2001 From: Marek Libra Date: Tue, 23 Apr 2024 14:07:31 +0200 Subject: [PATCH] patch(notifications): skip rendering empty descriptions Signed-off-by: Marek Libra --- .changeset/stupid-onions-know.md | 5 +++++ .../components/NotificationsTable/NotificationsTable.tsx | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 .changeset/stupid-onions-know.md diff --git a/.changeset/stupid-onions-know.md b/.changeset/stupid-onions-know.md new file mode 100644 index 0000000000..3d028557be --- /dev/null +++ b/.changeset/stupid-onions-know.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-notifications': patch +--- + +Empty descriptions are not rendered to improve the look&feel. diff --git a/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx b/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx index 3b34f9766b..f1d6e58b51 100644 --- a/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx +++ b/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx @@ -181,9 +181,11 @@ export const NotificationsTable = ({ notification.payload.title )} - - {notification.payload.description} - + {notification.payload.description ? ( + + {notification.payload.description} + + ) : null} {notification.origin && ( <>{notification.origin} •