react-notify-sdk 1.0.23 → 1.0.25

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.
@@ -10,6 +10,6 @@ top: ${(props) => props.message?.position === 'top' ? '24px' : ''};
10
10
  bottom: ${(props) => props.message?.position === 'bottom' ? '24px' : ''};
11
11
  left: 50%;
12
12
  transform: translateX(-50%);
13
- z-index: 5;
13
+ z-index: 5000;
14
14
  `;
15
15
  export default FadeWrapper;
@@ -1,5 +1,19 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  const NotificationMessage = ({ message }) => {
3
+ function hexToRgba(hex, alpha) {
4
+ // Remove leading #
5
+ hex = hex.replace(/^#/, "");
6
+ // Expand shorthand form (#03F → #0033FF)
7
+ if (hex.length === 3) {
8
+ hex = hex.split("").map(x => x + x).join("");
9
+ }
10
+ // Parse into r, g, b
11
+ const bigint = parseInt(hex, 16);
12
+ const r = (bigint >> 16) & 255;
13
+ const g = (bigint >> 8) & 255;
14
+ const b = bigint & 255;
15
+ return `rgba(${r}, ${g}, ${b}, ${alpha})`;
16
+ }
3
17
  return (_jsxs("div", { style: {
4
18
  width: '100%',
5
19
  paddingTop: '4px', // p-4 = 1rem
@@ -7,8 +21,10 @@ const NotificationMessage = ({ message }) => {
7
21
  paddingLeft: '12px',
8
22
  paddingRight: '12px',
9
23
  backgroundColor: message?.backgroundColor,
10
- border: `1px solid ${message?.textColor}`, // Completed border style
11
- borderRadius: "8px"
24
+ borderRadius: "8px",
25
+ borderWidth: "1px",
26
+ borderColor: `${hexToRgba(message.borderColor, 0.3)}`,
27
+ boxShadow: `0 10px 15px -3px ${hexToRgba(message.borderColor, 0.4)}, 0 4px 6px -4px ${hexToRgba(message.borderColor, 0.4)}`
12
28
  }, children: [_jsxs("div", { className: 'w-full flex flex-row', style: {
13
29
  width: '100%',
14
30
  display: 'flex',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-notify-sdk",
3
- "version": "1.0.23",
3
+ "version": "1.0.25",
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",
@@ -17,7 +17,8 @@
17
17
  "dependencies": {
18
18
  "@supabase/supabase-js": "^2.50.0",
19
19
  "clsx": "^2.1.1",
20
- "goober": "^2.1.16"
20
+ "goober": "^2.1.16",
21
+ "lucide-react": "^0.541.0"
21
22
  },
22
23
  "devDependencies": {
23
24
  "@types/react": "^19.1.8",