react-notify-sdk 1.0.39 → 1.0.41
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/dist/FadeWrapper.d.ts +3 -2
- package/dist/FadeWrapper.js +17 -14
- package/dist/index.js +0 -3
- package/package.json +2 -4
package/dist/FadeWrapper.d.ts
CHANGED
|
@@ -3,7 +3,8 @@ import { FeatureMessages } from './types';
|
|
|
3
3
|
interface FadeWrapperProps {
|
|
4
4
|
visible: boolean;
|
|
5
5
|
message: FeatureMessages;
|
|
6
|
-
device: string;
|
|
6
|
+
device: string | null;
|
|
7
|
+
children: React.ReactNode;
|
|
7
8
|
}
|
|
8
|
-
|
|
9
|
+
declare const FadeWrapper: React.FC<FadeWrapperProps>;
|
|
9
10
|
export default FadeWrapper;
|
package/dist/FadeWrapper.js
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
const FadeWrapper = ({ visible, message, device, children }) => {
|
|
3
|
+
const width = device === 'Mobile' ? '95%' : '420px';
|
|
4
|
+
const top = message?.position === 'top' ? '24px' : 'auto';
|
|
5
|
+
const bottom = message?.position === 'bottom' ? '24px' : 'auto';
|
|
6
|
+
return (_jsx("div", { style: {
|
|
7
|
+
opacity: visible ? 1 : 0,
|
|
8
|
+
transition: 'opacity 0.3s ease',
|
|
9
|
+
position: 'fixed',
|
|
10
|
+
width: width,
|
|
11
|
+
top: top,
|
|
12
|
+
bottom: bottom,
|
|
13
|
+
left: '50%',
|
|
14
|
+
transform: 'translateX(-50%)',
|
|
15
|
+
zIndex: 9999,
|
|
16
|
+
}, children: children }));
|
|
17
|
+
};
|
|
15
18
|
export default FadeWrapper;
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-notify-sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.41",
|
|
4
4
|
"description": "SDK for displaying real-time route-specific messages in React apps",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -24,12 +24,10 @@
|
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@types/react": "^19.1.13",
|
|
26
26
|
"@types/react-dom": "^19.1.9",
|
|
27
|
-
"@types/react-router-dom": "^5.3.3",
|
|
28
27
|
"typescript": "^5.9.2"
|
|
29
28
|
},
|
|
30
29
|
"peerDependencies": {
|
|
31
30
|
"react": "^19.1.1",
|
|
32
|
-
"react-dom": "^19.1.1"
|
|
33
|
-
"react-router-dom": "^7.6.2"
|
|
31
|
+
"react-dom": "^19.1.1"
|
|
34
32
|
}
|
|
35
33
|
}
|