@commercetools-frontend/react-notifications 22.2.0 → 22.3.0

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.
@@ -4,7 +4,7 @@ export type Props = {
4
4
  mapNotificationToComponent: (notification: TAppNotificationGlobal | TAppNotificationPage | TAppNotificationSide) => ElementType | null;
5
5
  children: ReactNode;
6
6
  };
7
- declare function NotificationProviderForCustomComponent(props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
7
+ declare function NotificationProviderForCustomComponent(props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
8
8
  declare namespace NotificationProviderForCustomComponent {
9
9
  var displayName: string;
10
10
  }
@@ -8,7 +8,7 @@ export type Props = {
8
8
  children: ReactNode;
9
9
  };
10
10
  declare const Notification: {
11
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
11
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
12
12
  displayName: string;
13
13
  defaultProps: Pick<Props, "fixed">;
14
14
  };
@@ -1,3 +1,4 @@
1
+ import { type SerializedStyles } from '@emotion/react';
1
2
  import type { TAppNotificationKind, TAppNotificationDomain } from '@commercetools-frontend/constants';
2
3
  type StyleProps = {
3
4
  type: TAppNotificationKind;
@@ -5,8 +6,8 @@ type StyleProps = {
5
6
  fixed: boolean;
6
7
  isNewTheme?: boolean;
7
8
  };
8
- declare const getStylesForNotificationIcon: (props: StyleProps) => import("@emotion/utils").SerializedStyles;
9
- declare const getStylesForCloseIcon: (props: StyleProps) => import("@emotion/utils").SerializedStyles;
10
- declare const getStylesForContent: (props: StyleProps) => import("@emotion/utils").SerializedStyles;
11
- declare const getStylesForNotification: (props: StyleProps) => import("@emotion/utils").SerializedStyles;
9
+ declare const getStylesForNotificationIcon: (props: StyleProps) => SerializedStyles;
10
+ declare const getStylesForCloseIcon: (props: StyleProps) => SerializedStyles;
11
+ declare const getStylesForContent: (props: StyleProps) => SerializedStyles;
12
+ declare const getStylesForNotification: (props: StyleProps) => SerializedStyles;
12
13
  export { getStylesForNotificationIcon, getStylesForCloseIcon, getStylesForContent, getStylesForNotification, };
@@ -10,7 +10,7 @@ type Props = {
10
10
  dismiss: (event: SyntheticEvent) => void;
11
11
  };
12
12
  declare const ApiErrorNotification: {
13
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
13
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
14
14
  displayName: string;
15
15
  };
16
16
  export default ApiErrorNotification;
@@ -1,5 +1,5 @@
1
1
  import type { TAppNotificationApiError } from '@commercetools-frontend/constants';
2
- type ExtraErrorFields = {
2
+ export type ExtraErrorFields = {
3
3
  errorByExtension?: {
4
4
  id: string;
5
5
  key?: string;
@@ -20,12 +20,16 @@ type ExtraErrorFields = {
20
20
  name: string;
21
21
  };
22
22
  referencedBy?: string;
23
+ extensions?: TAppNotificationApiError['extensions'] & {
24
+ field?: string;
25
+ duplicateValue?: string;
26
+ };
23
27
  };
24
28
  type Props = {
25
29
  error: TAppNotificationApiError<ExtraErrorFields>;
26
30
  };
27
31
  declare const ApiErrorMessage: {
28
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
32
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
29
33
  displayName: string;
30
34
  };
31
35
  export default ApiErrorMessage;
@@ -9,7 +9,7 @@ type Props = {
9
9
  dismiss: (event: SyntheticEvent) => void;
10
10
  };
11
11
  declare const GenericNotification: {
12
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
12
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
13
13
  displayName: string;
14
14
  };
15
15
  export default GenericNotification;
@@ -10,7 +10,7 @@ type Props = {
10
10
  dismiss: (event: SyntheticEvent) => void;
11
11
  };
12
12
  declare const UnexpectedErrorNotification: {
13
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element;
13
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
14
14
  displayName: string;
15
15
  };
16
16
  export default UnexpectedErrorNotification;
@@ -3,7 +3,7 @@ type Props = {
3
3
  domain: TAppNotificationDomain;
4
4
  };
5
5
  declare const NotificationsList: {
6
- (props: Props): import("@emotion/react/jsx-runtime").JSX.Element | null;
6
+ (props: Props): import("@emotion/react/types/jsx-namespace").EmotionJSX.Element | null;
7
7
  displayName: string;
8
8
  };
9
9
  export default NotificationsList;
@@ -2,5 +2,5 @@ import type { TAppNotificationDomain } from '@commercetools-frontend/constants';
2
2
  type StyleProps = {
3
3
  domain: TAppNotificationDomain;
4
4
  };
5
- declare const getStyles: (props: StyleProps) => import("@emotion/utils").SerializedStyles;
5
+ declare const getStyles: (props: StyleProps) => import("@emotion/react").SerializedStyles;
6
6
  export { getStyles };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commercetools-frontend/react-notifications",
3
- "version": "22.2.0",
3
+ "version": "22.3.0",
4
4
  "description": "React bindings for @commercetools-frontend/notifications",
5
5
  "bugs": "https://github.com/commercetools/merchant-center-application-kit/issues",
6
6
  "repository": {
@@ -9,21 +9,31 @@
9
9
  "directory": "packages/react-notifications"
10
10
  },
11
11
  "homepage": "https://docs.commercetools.com/custom-applications",
12
- "keywords": ["javascript", "frontend", "react", "toolkit"],
12
+ "keywords": [
13
+ "javascript",
14
+ "frontend",
15
+ "react",
16
+ "toolkit"
17
+ ],
13
18
  "license": "MIT",
14
19
  "publishConfig": {
15
20
  "access": "public"
16
21
  },
17
22
  "main": "dist/commercetools-frontend-react-notifications.cjs.js",
18
23
  "module": "dist/commercetools-frontend-react-notifications.esm.js",
19
- "files": ["dist", "package.json", "LICENSE", "README.md"],
24
+ "files": [
25
+ "dist",
26
+ "package.json",
27
+ "LICENSE",
28
+ "README.md"
29
+ ],
20
30
  "dependencies": {
21
31
  "@babel/runtime": "^7.20.13",
22
32
  "@babel/runtime-corejs3": "^7.20.13",
23
- "@commercetools-frontend/actions-global": "22.2.0",
24
- "@commercetools-frontend/constants": "22.2.0",
25
- "@commercetools-frontend/notifications": "22.2.0",
26
- "@commercetools-frontend/sentry": "22.2.0",
33
+ "@commercetools-frontend/actions-global": "22.3.0",
34
+ "@commercetools-frontend/constants": "22.3.0",
35
+ "@commercetools-frontend/notifications": "22.3.0",
36
+ "@commercetools-frontend/sentry": "22.3.0",
27
37
  "@commercetools-uikit/design-system": "^16.0.0",
28
38
  "@commercetools-uikit/hooks": "^16.0.0",
29
39
  "@commercetools-uikit/icon-button": "^16.0.0",
@@ -31,8 +41,8 @@
31
41
  "@commercetools-uikit/secondary-icon-button": "^16.0.0",
32
42
  "@commercetools-uikit/spacings": "^16.0.0",
33
43
  "@commercetools-uikit/utils": "^16.0.0",
34
- "@emotion/react": "11.10.6",
35
- "@emotion/styled": "11.10.6",
44
+ "@emotion/react": "11.11.0",
45
+ "@emotion/styled": "11.11.0",
36
46
  "@types/history": "^4.7.11",
37
47
  "@types/lodash": "^4.14.191",
38
48
  "@types/prop-types": "^15.7.5",
@@ -48,10 +58,13 @@
48
58
  "reselect": "4.1.8"
49
59
  },
50
60
  "devDependencies": {
51
- "@testing-library/react": "12.1.5",
61
+ "@types/jest": "^29.5.1",
62
+ "@types/testing-library__jest-dom": "^5.14.5",
63
+ "jest": "29.5.0",
64
+ "jest-mock": "29.5.0",
52
65
  "react": "17.0.2",
53
66
  "react-dom": "17.0.2",
54
- "react-intl": "^6.3.2",
67
+ "react-intl": "^6.4.2",
55
68
  "react-redux": "7.2.9",
56
69
  "react-router-dom": "5.3.4"
57
70
  },
@@ -62,4 +75,4 @@
62
75
  "react-redux": "7.x",
63
76
  "react-router-dom": "5.x"
64
77
  }
65
- }
78
+ }