@vuu-ui/vuu-notifications 3.3.12 → 3.3.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "3.3.12",
2
+ "version": "3.3.14",
3
3
  "description": "VUU notifications - Toast, WorkspaceNotification etc",
4
4
  "main": "./src/index.js",
5
5
  "author": "heswell",
@@ -13,8 +13,8 @@
13
13
  "@salt-ds/core": "1.54.1",
14
14
  "@salt-ds/styles": "0.2.1",
15
15
  "@salt-ds/window": "0.1.1",
16
- "@vuu-ui/vuu-ui-controls": "3.3.12",
17
- "@vuu-ui/vuu-utils": "3.3.12"
16
+ "@vuu-ui/vuu-ui-controls": "3.3.14",
17
+ "@vuu-ui/vuu-utils": "3.3.14"
18
18
  },
19
19
  "peerDependencies": {
20
20
  "clsx": "^2.0.0",
@@ -95,15 +95,9 @@ const NotificationsCenter = ({ notificationsContext, startupToastNotification })
95
95
  return newToast;
96
96
  }
97
97
  }));
98
- if (scheduledUpdate) {
99
- const updateNotifications = notificationsRef.current.map((n)=>{
100
- if (n.id === scheduledUpdate?.id) return scheduledUpdate;
101
- return n;
102
- });
103
- requestAnimationFrame(()=>{
104
- setNotifications(updateNotifications);
105
- });
106
- }
98
+ if (scheduledUpdate) requestAnimationFrame(()=>{
99
+ setNotifications(notificationsRef.current.map((n)=>n.id === scheduledUpdate?.id ? scheduledUpdate : n));
100
+ });
107
101
  }, [
108
102
  setNotifications
109
103
  ]);