@mantine/notifications 4.1.2 → 4.1.5

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.
@@ -8,7 +8,7 @@ function getPositionStyles([vertical, horizontal], containerWidth, spacing) {
8
8
  vertical === "bottom" && (styles.bottom = spacing);
9
9
  horizontal === "left" && (styles.left = spacing);
10
10
  horizontal === "right" && (styles.right = spacing);
11
- horizontal === "center" && (styles.left = `calc(50% - ${containerWidth / 2}px)`);
11
+ horizontal === "center" && (styles.left = "50%", styles.transform = "translateX(-50%)");
12
12
  return styles;
13
13
  }
14
14
 
@@ -1 +1 @@
1
- {"version":3,"file":"get-position-styles.js","sources":["../../../src/NotificationsProvider/get-position-styles/get-position-styles.ts"],"sourcesContent":["import { CSSObject } from '@mantine/core';\nimport { NotificationsProviderPositioning } from '../../types';\n\nexport default function getPositionStyles(\n [vertical, horizontal]: NotificationsProviderPositioning,\n containerWidth: number,\n spacing: number\n) {\n const styles: CSSObject = {};\n\n vertical === 'top' && (styles.top = spacing);\n vertical === 'bottom' && (styles.bottom = spacing);\n\n horizontal === 'left' && (styles.left = spacing);\n horizontal === 'right' && (styles.right = spacing);\n horizontal === 'center' && (styles.left = `calc(50% - ${containerWidth / 2}px)`);\n\n return styles;\n}\n"],"names":[],"mappings":";;;;AAAe,SAAS,iBAAiB,CAAC,CAAC,QAAQ,EAAE,UAAU,CAAC,EAAE,cAAc,EAAE,OAAO,EAAE;AAC3F,EAAE,MAAM,MAAM,GAAG,EAAE,CAAC;AACpB,EAAE,QAAQ,KAAK,KAAK,KAAK,MAAM,CAAC,GAAG,GAAG,OAAO,CAAC,CAAC;AAC/C,EAAE,QAAQ,KAAK,QAAQ,KAAK,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,MAAM,KAAK,MAAM,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;AACnD,EAAE,UAAU,KAAK,OAAO,KAAK,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,QAAQ,KAAK,MAAM,CAAC,IAAI,GAAG,CAAC,WAAW,EAAE,cAAc,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;AACnF,EAAE,OAAO,MAAM,CAAC;AAChB;;;;"}
1
+ {"version":3,"file":"get-position-styles.js","sources":["../../../src/NotificationsProvider/get-position-styles/get-position-styles.ts"],"sourcesContent":["import { CSSObject } from '@mantine/core';\nimport { NotificationsProviderPositioning } from '../../types';\n\nexport default function getPositionStyles(\n [vertical, horizontal]: NotificationsProviderPositioning,\n containerWidth: number,\n spacing: number\n) {\n const styles: CSSObject = {};\n\n vertical === 'top' && (styles.top = spacing);\n vertical === 'bottom' && (styles.bottom = spacing);\n\n horizontal === 'left' && (styles.left = spacing);\n horizontal === 'right' && (styles.right = spacing);\n horizontal === 'center' && ((styles.left = '50%'), (styles.transform = 'translateX(-50%)'));\n\n return styles;\n}\n"],"names":[],"mappings":";;;;AAAe,SAAS,iBAAiB,CAAC,CAAC,QAAQ,EAAE,UAAU,CAAC,EAAE,cAAc,EAAE,OAAO,EAAE;AAC3F,EAAE,MAAM,MAAM,GAAG,EAAE,CAAC;AACpB,EAAE,QAAQ,KAAK,KAAK,KAAK,MAAM,CAAC,GAAG,GAAG,OAAO,CAAC,CAAC;AAC/C,EAAE,QAAQ,KAAK,QAAQ,KAAK,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,MAAM,KAAK,MAAM,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;AACnD,EAAE,UAAU,KAAK,OAAO,KAAK,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,QAAQ,KAAK,MAAM,CAAC,IAAI,GAAG,KAAK,EAAE,MAAM,CAAC,SAAS,GAAG,kBAAkB,CAAC,CAAC;AAC1F,EAAE,OAAO,MAAM,CAAC;AAChB;;;;"}
@@ -4,7 +4,7 @@ function getPositionStyles([vertical, horizontal], containerWidth, spacing) {
4
4
  vertical === "bottom" && (styles.bottom = spacing);
5
5
  horizontal === "left" && (styles.left = spacing);
6
6
  horizontal === "right" && (styles.right = spacing);
7
- horizontal === "center" && (styles.left = `calc(50% - ${containerWidth / 2}px)`);
7
+ horizontal === "center" && (styles.left = "50%", styles.transform = "translateX(-50%)");
8
8
  return styles;
9
9
  }
10
10
 
@@ -1 +1 @@
1
- {"version":3,"file":"get-position-styles.js","sources":["../../../src/NotificationsProvider/get-position-styles/get-position-styles.ts"],"sourcesContent":["import { CSSObject } from '@mantine/core';\nimport { NotificationsProviderPositioning } from '../../types';\n\nexport default function getPositionStyles(\n [vertical, horizontal]: NotificationsProviderPositioning,\n containerWidth: number,\n spacing: number\n) {\n const styles: CSSObject = {};\n\n vertical === 'top' && (styles.top = spacing);\n vertical === 'bottom' && (styles.bottom = spacing);\n\n horizontal === 'left' && (styles.left = spacing);\n horizontal === 'right' && (styles.right = spacing);\n horizontal === 'center' && (styles.left = `calc(50% - ${containerWidth / 2}px)`);\n\n return styles;\n}\n"],"names":[],"mappings":"AAAe,SAAS,iBAAiB,CAAC,CAAC,QAAQ,EAAE,UAAU,CAAC,EAAE,cAAc,EAAE,OAAO,EAAE;AAC3F,EAAE,MAAM,MAAM,GAAG,EAAE,CAAC;AACpB,EAAE,QAAQ,KAAK,KAAK,KAAK,MAAM,CAAC,GAAG,GAAG,OAAO,CAAC,CAAC;AAC/C,EAAE,QAAQ,KAAK,QAAQ,KAAK,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,MAAM,KAAK,MAAM,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;AACnD,EAAE,UAAU,KAAK,OAAO,KAAK,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,QAAQ,KAAK,MAAM,CAAC,IAAI,GAAG,CAAC,WAAW,EAAE,cAAc,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;AACnF,EAAE,OAAO,MAAM,CAAC;AAChB;;;;"}
1
+ {"version":3,"file":"get-position-styles.js","sources":["../../../src/NotificationsProvider/get-position-styles/get-position-styles.ts"],"sourcesContent":["import { CSSObject } from '@mantine/core';\nimport { NotificationsProviderPositioning } from '../../types';\n\nexport default function getPositionStyles(\n [vertical, horizontal]: NotificationsProviderPositioning,\n containerWidth: number,\n spacing: number\n) {\n const styles: CSSObject = {};\n\n vertical === 'top' && (styles.top = spacing);\n vertical === 'bottom' && (styles.bottom = spacing);\n\n horizontal === 'left' && (styles.left = spacing);\n horizontal === 'right' && (styles.right = spacing);\n horizontal === 'center' && ((styles.left = '50%'), (styles.transform = 'translateX(-50%)'));\n\n return styles;\n}\n"],"names":[],"mappings":"AAAe,SAAS,iBAAiB,CAAC,CAAC,QAAQ,EAAE,UAAU,CAAC,EAAE,cAAc,EAAE,OAAO,EAAE;AAC3F,EAAE,MAAM,MAAM,GAAG,EAAE,CAAC;AACpB,EAAE,QAAQ,KAAK,KAAK,KAAK,MAAM,CAAC,GAAG,GAAG,OAAO,CAAC,CAAC;AAC/C,EAAE,QAAQ,KAAK,QAAQ,KAAK,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,MAAM,KAAK,MAAM,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;AACnD,EAAE,UAAU,KAAK,OAAO,KAAK,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,CAAC;AACrD,EAAE,UAAU,KAAK,QAAQ,KAAK,MAAM,CAAC,IAAI,GAAG,KAAK,EAAE,MAAM,CAAC,SAAS,GAAG,kBAAkB,CAAC,CAAC;AAC1F,EAAE,OAAO,MAAM,CAAC;AAChB;;;;"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mantine/notifications",
3
3
  "description": "Notification system based on Mantine components",
4
- "version": "4.1.2",
4
+ "version": "4.1.5",
5
5
  "main": "cjs/index.js",
6
6
  "module": "esm/index.js",
7
7
  "types": "lib/index.d.ts",
@@ -28,8 +28,8 @@
28
28
  "notification-system"
29
29
  ],
30
30
  "peerDependencies": {
31
- "@mantine/core": "4.1.2",
32
- "@mantine/hooks": "4.1.2",
31
+ "@mantine/core": "4.1.5",
32
+ "@mantine/hooks": "4.1.5",
33
33
  "react": ">=16.8.0",
34
34
  "react-dom": ">=16.8.0"
35
35
  },