magneto365.ui 2.58.1 → 2.59.1

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.
Files changed (38) hide show
  1. package/dist/cjs/css/magneto.ui.lib.min.css +1 -1
  2. package/dist/cjs/index.js +496 -438
  3. package/dist/cjs/index.js.map +1 -1
  4. package/dist/cjs/types/components/UI/molecules/MegaMenuSideCards/MegaMenuSideCards.interface.d.ts +26 -0
  5. package/dist/cjs/types/components/UI/molecules/MegaMenuSideCards/index.d.ts +1 -0
  6. package/dist/cjs/types/components/UI/molecules/Notification/Notification.component.d.ts +4 -0
  7. package/dist/cjs/types/components/UI/molecules/Notification/Notification.interface.d.ts +35 -0
  8. package/dist/cjs/types/components/UI/molecules/Notification/index.d.ts +2 -0
  9. package/dist/cjs/types/components/UI/molecules/index.d.ts +1 -0
  10. package/dist/cjs/types/components/UI/template/MegaMenu/MegaMenu.component.d.ts +3 -1
  11. package/dist/cjs/types/components/hoc/index.d.ts +1 -1
  12. package/dist/cjs/types/components/hoc/megaMenu/withSideCards.d.ts +9 -0
  13. package/dist/cjs/types/components/hoc/megaMenu/withSideCards.desktop.d.ts +8 -0
  14. package/dist/cjs/types/components/hoc/megaMenu/withSideCardsDrawer.mobile.d.ts +8 -0
  15. package/dist/cjs/types/components/hoc/megaMenu/withSideCardsMobile.d.ts +9 -0
  16. package/dist/cjs/types/constants/stories/index.d.ts +1 -0
  17. package/dist/cjs/types/constants/stories/notification.constants.d.ts +2 -0
  18. package/dist/esm/css/magneto.ui.lib.min.css +1 -1
  19. package/dist/esm/index.js +495 -438
  20. package/dist/esm/index.js.map +1 -1
  21. package/dist/esm/types/components/UI/molecules/MegaMenuSideCards/MegaMenuSideCards.interface.d.ts +26 -0
  22. package/dist/esm/types/components/UI/molecules/MegaMenuSideCards/index.d.ts +1 -0
  23. package/dist/esm/types/components/UI/molecules/Notification/Notification.component.d.ts +4 -0
  24. package/dist/esm/types/components/UI/molecules/Notification/Notification.interface.d.ts +35 -0
  25. package/dist/esm/types/components/UI/molecules/Notification/index.d.ts +2 -0
  26. package/dist/esm/types/components/UI/molecules/index.d.ts +1 -0
  27. package/dist/esm/types/components/UI/template/MegaMenu/MegaMenu.component.d.ts +3 -1
  28. package/dist/esm/types/components/hoc/index.d.ts +1 -1
  29. package/dist/esm/types/components/hoc/megaMenu/withSideCards.d.ts +9 -0
  30. package/dist/esm/types/components/hoc/megaMenu/withSideCards.desktop.d.ts +8 -0
  31. package/dist/esm/types/components/hoc/megaMenu/withSideCardsDrawer.mobile.d.ts +8 -0
  32. package/dist/esm/types/components/hoc/megaMenu/withSideCardsMobile.d.ts +9 -0
  33. package/dist/esm/types/constants/stories/index.d.ts +1 -0
  34. package/dist/esm/types/constants/stories/notification.constants.d.ts +2 -0
  35. package/dist/index.d.ts +69 -5
  36. package/package.json +1 -1
  37. package/dist/cjs/types/components/hoc/megaMenu/withContainer.d.ts +0 -7
  38. package/dist/esm/types/components/hoc/megaMenu/withContainer.d.ts +0 -7
@@ -1,9 +1,35 @@
1
1
  import { IMegaMenuCard } from '@components/UI/molecules';
2
2
  import { IMegaMenuLink } from '@components/UI/template/MegaMenu/MegaMenuContext.interface';
3
+ import { Ref } from 'react';
3
4
  export interface IMegaMenuSideCards {
5
+ /**
6
+ * Array of jobs for each card
7
+ */
4
8
  jobs: IMegaMenuCard[];
9
+ /**
10
+ * CallBack when a card is selected
11
+ */
5
12
  onSelectCard?: (index: number) => void;
13
+ /**
14
+ * Actrion button on the end of the component
15
+ */
6
16
  action?: IMegaMenuLink;
17
+ /**
18
+ * Max amount of cards
19
+ */
7
20
  maxCards?: number;
21
+ /**
22
+ * Initial selected card
23
+ */
8
24
  initValue?: number;
25
+ /**
26
+ * Reference for iterative bnehaviour
27
+ */
28
+ cardsRef?: Ref<ICardsRef>;
29
+ }
30
+ export interface ICardsRef {
31
+ /**
32
+ * CallBack to restart filters
33
+ */
34
+ setSelectedCard: (index: number) => void;
9
35
  }
@@ -1 +1,2 @@
1
1
  export { default as MegaMenuSideCards } from './MegaMenuSideCards.component';
2
+ export * from './MegaMenuSideCards.interface';
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { INotification } from './Notification.interface';
3
+ declare const Notification: React.FC<INotification>;
4
+ export default Notification;
@@ -0,0 +1,35 @@
1
+ /// <reference types="react" />
2
+ /**
3
+ * Defines the position of the Notification component
4
+ */
5
+ declare type NotificationPosition = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
6
+ /**
7
+ * Interface for Notification component props
8
+ */
9
+ export interface INotification {
10
+ /**
11
+ * Callback function to close the notification
12
+ */
13
+ onClose: () => void;
14
+ /**
15
+ * Message to display in the notification
16
+ */
17
+ message?: React.ReactNode;
18
+ /**
19
+ * Position where the notification will appear
20
+ */
21
+ position?: NotificationPosition;
22
+ /**
23
+ * Custom class for styling the notification container
24
+ */
25
+ className?: string;
26
+ /**
27
+ * Duration in milliseconds before auto-closing the notification
28
+ */
29
+ autoCloseDuration?: number;
30
+ /**
31
+ * Extra content to display in the notification
32
+ */
33
+ extraContent?: React.ReactNode;
34
+ }
35
+ export {};
@@ -0,0 +1,2 @@
1
+ export * from './Notification.interface';
2
+ export { default as Notification } from './Notification.component';
@@ -72,3 +72,4 @@ export * from './UserMenuWrapperAnalyst';
72
72
  export * from './AlertJobStatus';
73
73
  export * from './SimilarCard';
74
74
  export * from './MegaMenuDrawerItem';
75
+ export * from './Notification';
@@ -5,7 +5,9 @@ export declare const MegaMenu: React.FC<IMegaMenuContext & IMegaMenu> & {
5
5
  Cards: React.FC<import("@components/UI/organism").IMegaMenuCards>;
6
6
  Card: React.FC<import("@components/UI/molecules").IMegaMenuCard>;
7
7
  SideCards: React.FC<{
8
- sideProps: import("../../molecules/MegaMenuSideCards/MegaMenuSideCards.interface").IMegaMenuSideCards;
8
+ sideProps: import("@components/UI/molecules").IMegaMenuSideCards;
9
9
  wrapperProps: import("@components/UI/organism").IMegaMenuCards;
10
+ withDrawerAction?: boolean | undefined;
11
+ showContent?: boolean | undefined;
10
12
  }>;
11
13
  };
@@ -1,2 +1,2 @@
1
1
  export { default as withClickOut } from './withClickOut';
2
- export { default as withMegaMenuContainer } from './megaMenu/withContainer';
2
+ export { default as withMegaMenuSideCards } from './megaMenu/withSideCards';
@@ -0,0 +1,9 @@
1
+ import { IMegaMenuSideCards } from '@components/UI/molecules';
2
+ import React from 'react';
3
+ declare const withMegaMenuSideCards: <T>(WrappedComponent: React.FC<T>) => React.FC<{
4
+ sideProps: IMegaMenuSideCards;
5
+ wrapperProps: T;
6
+ withDrawerAction?: boolean | undefined;
7
+ showContent?: boolean | undefined;
8
+ }>;
9
+ export default withMegaMenuSideCards;
@@ -0,0 +1,8 @@
1
+ import { IMegaMenuSideCards } from '@components/UI/molecules';
2
+ import React from 'react';
3
+ declare const DesktopSideCards: <T>({ WrappedComponent, sideProps, wrapperProps }: {
4
+ WrappedComponent: React.FC<T>;
5
+ sideProps: IMegaMenuSideCards;
6
+ wrapperProps: T;
7
+ }) => JSX.Element;
8
+ export default DesktopSideCards;
@@ -0,0 +1,8 @@
1
+ import { IMegaMenuSideCards } from '@components/UI/molecules';
2
+ import React from 'react';
3
+ declare const MobileSideCardsDrawer: <T>({ WrappedComponent, sideProps, wrapperProps }: {
4
+ WrappedComponent: React.FC<T>;
5
+ sideProps: IMegaMenuSideCards;
6
+ wrapperProps: T;
7
+ }) => JSX.Element;
8
+ export default MobileSideCardsDrawer;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import { IMegaMenuSideCards } from '@components/UI/molecules';
3
+ declare const MobileSideCards: <T>({ WrappedComponent, sideProps, wrapperProps, showContent }: {
4
+ WrappedComponent: React.FC<T>;
5
+ sideProps: IMegaMenuSideCards;
6
+ wrapperProps: T;
7
+ showContent: boolean;
8
+ }) => JSX.Element;
9
+ export default MobileSideCards;
@@ -22,3 +22,4 @@ export * from './megaMenu.constants';
22
22
  export * from './alertJob.constants';
23
23
  export * from './similarCard.constants';
24
24
  export * from './jobSuggestedDrawer.constants';
25
+ export * from './notification.constants';
@@ -0,0 +1,2 @@
1
+ import { INotification } from '@components/UI/molecules/Notification';
2
+ export declare const notification: INotification;