From 02ada20ce5f0d332501056057df8e6d5a351d8c8 Mon Sep 17 00:00:00 2001 From: Peter Ling Date: Tue, 28 Nov 2023 14:37:03 +0000 Subject: [PATCH 1/2] SLVUU-123: Add nominal timeout before setting toast position --- .../vuu-popups/src/notifications/NotificationsProvider.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx b/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx index eadbc5825..37964aba6 100644 --- a/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx +++ b/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx @@ -94,7 +94,10 @@ export const ToastNotification = (props: ToastNotificationProps) => { const [right, setRight] = useState(-toastWidth - toastContainerRightPadding); useEffect(() => { - setRight(toastContainerRightPadding); + setTimeout( + () => setRight(toastContainerRightPadding) + ); + if (animated) { setTimeout( () => setRight(-toastWidth - toastContainerRightPadding), From 019035081c696e07a77ec2fd448d4311dc7ac826 Mon Sep 17 00:00:00 2001 From: Peter Ling Date: Tue, 28 Nov 2023 17:15:55 +0000 Subject: [PATCH 2/2] SLVUU-123: Remove toastContainer class --- .../src/notifications/NotificationsProvider.tsx | 1 - .../vuu-popups/src/notifications/notifications.css | 10 ---------- 2 files changed, 11 deletions(-) diff --git a/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx b/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx index 37964aba6..9fd2c67e9 100644 --- a/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx +++ b/vuu-ui/packages/vuu-popups/src/notifications/NotificationsProvider.tsx @@ -60,7 +60,6 @@ export const NotificationsProvider = (props: { return (