analytica-frontend-lib 1.1.63 → 1.1.65

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.
@@ -1401,6 +1401,11 @@ var mock_content_default = "../mock-content-K2CDVG6P.png";
1401
1401
 
1402
1402
  // src/components/NotificationCard/NotificationCard.tsx
1403
1403
  import { Fragment as Fragment2, jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
1404
+ var syncNotificationState = (open, isNotificationActive, setActiveStates, key = "notifications") => {
1405
+ if (!open && isNotificationActive) {
1406
+ setActiveStates((prev) => ({ ...prev, [key]: false }));
1407
+ }
1408
+ };
1404
1409
  var NotificationEmpty = ({
1405
1410
  emptyStateImage,
1406
1411
  emptyStateTitle = "Nenhuma notifica\xE7\xE3o no momento",
@@ -1737,6 +1742,20 @@ var NotificationCenter = ({
1737
1742
  ) })
1738
1743
  ] })
1739
1744
  }
1745
+ ),
1746
+ /* @__PURE__ */ jsx10(
1747
+ Modal_default,
1748
+ {
1749
+ isOpen: globalNotificationModal.isOpen,
1750
+ onClose: () => setGlobalNotificationModal({ isOpen: false, notification: null }),
1751
+ title: globalNotificationModal.notification?.title || "",
1752
+ variant: "activity",
1753
+ description: globalNotificationModal.notification?.message,
1754
+ image: emptyStateImage || mock_content_default,
1755
+ actionLink: globalNotificationModal.notification?.actionLink || void 0,
1756
+ actionLabel: "Ver mais",
1757
+ size: "lg"
1758
+ }
1740
1759
  )
1741
1760
  ] });
1742
1761
  }
@@ -1943,6 +1962,7 @@ var LegacyNotificationCard = (props) => {
1943
1962
  var NotificationCard_default = NotificationCard;
1944
1963
  export {
1945
1964
  LegacyNotificationCard,
1946
- NotificationCard_default as default
1965
+ NotificationCard_default as default,
1966
+ syncNotificationState
1947
1967
  };
1948
1968
  //# sourceMappingURL=index.mjs.map