tek-wallet 0.0.419 → 0.0.422

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.
@@ -94,7 +94,7 @@ var QrCodeReader = (0, react_1.forwardRef)(function (props, ref) {
94
94
  right: "1rem",
95
95
  zIndex: 6000,
96
96
  cursor: "pointer",
97
- color: "text.white",
97
+ color: "#fff",
98
98
  }, children: "Cancel" })] })) }));
99
99
  });
100
100
  QrCodeReader.displayName = "QrCodeReader";
@@ -640,7 +640,7 @@ var WithdrawFunction = (0, react_1.forwardRef)(function (props, ref) {
640
640
  return ((0, jsx_runtime_1.jsxs)(react_1.Fragment, { children: [index !== 0 && (0, jsx_runtime_1.jsx)(material_1.Divider, {}), (0, jsx_runtime_1.jsx)(ListItemCustom_1.default, { title: item, description: item, icon: (0, getIcon_1.default)(item + "_icon"), onClick: function () {
641
641
  return handleSelectMethod(item);
642
642
  }, sx: {
643
- my: theme.mixins.customMargin.m12,
643
+ py: theme.mixins.customPadding.p12,
644
644
  } })] }, item));
645
645
  }) })] }, WithdrawStep.SELECT_METHOD), (0, jsx_runtime_1.jsx)(react_2.SwiperSlide, { children: (0, jsx_runtime_1.jsx)(material_1.Box, { sx: __assign(__assign({}, theme.mixins.column), { gap: theme.mixins.gaps.g12, height: "fit-content" }), children: withdrawToken === null || withdrawToken === void 0 ? void 0 : withdrawToken.map(function (item) {
646
646
  var stringifiedTokenData = JSON.stringify(item);
@@ -70,8 +70,8 @@ exports.initialRealtime = {
70
70
  isConnected: false,
71
71
  pushNotification: function () { },
72
72
  };
73
- function SlideTransition(props) {
74
- return (0, jsx_runtime_1.jsx)(Slide_1.default, __assign({}, props, { direction: "up" }));
73
+ function GrowTransition(props) {
74
+ return (0, jsx_runtime_1.jsx)(Slide_1.default, __assign({}, props, { direction: "down" }));
75
75
  }
76
76
  exports.RealtimeContext = react_1.default.createContext(exports.initialRealtime);
77
77
  function RealtimeProvider(_a) {
@@ -101,20 +101,22 @@ function RealtimeProvider(_a) {
101
101
  }
102
102
  }, [masterWallet]);
103
103
  var closeNotification = function (id) {
104
- setNotifications(function (prev) { return prev.filter(function (n) { return n.id !== id; }); });
104
+ setNotifications(function (prev) {
105
+ return prev.map(function (n) { return (n.id === id ? __assign(__assign({}, n), { open: false }) : n); });
106
+ });
105
107
  };
106
108
  return ((0, jsx_runtime_1.jsxs)(exports.RealtimeContext.Provider, { value: {
107
109
  isConnected: isConnected,
108
110
  transaction: transaction,
109
111
  pushNotification: pushNotification,
110
112
  }, children: [children, (0, jsx_runtime_1.jsx)(notistack_1.SnackbarProvider, { maxSnack: 2, children: notifications.map(function (notification) {
111
- var _a, _b, _c, _d, _e;
112
- return ((0, jsx_runtime_1.jsx)(material_1.Snackbar, { open: true, anchorOrigin: {
113
- vertical: (_b = (_a = notification === null || notification === void 0 ? void 0 : notification.anchorOrigin) === null || _a === void 0 ? void 0 : _a.vertical) !== null && _b !== void 0 ? _b : "top",
114
- horizontal: (_d = (_c = notification === null || notification === void 0 ? void 0 : notification.anchorOrigin) === null || _c === void 0 ? void 0 : _c.horizontal) !== null && _d !== void 0 ? _d : "right",
113
+ var _a, _b, _c, _d, _e, _f;
114
+ return ((0, jsx_runtime_1.jsx)(material_1.Snackbar, { open: (_a = notification.open) !== null && _a !== void 0 ? _a : true, anchorOrigin: {
115
+ vertical: (_c = (_b = notification === null || notification === void 0 ? void 0 : notification.anchorOrigin) === null || _b === void 0 ? void 0 : _b.vertical) !== null && _c !== void 0 ? _c : "top",
116
+ horizontal: (_e = (_d = notification === null || notification === void 0 ? void 0 : notification.anchorOrigin) === null || _d === void 0 ? void 0 : _d.horizontal) !== null && _e !== void 0 ? _e : "right",
115
117
  }, onClose: function () {
116
118
  closeNotification(notification.id);
117
- }, slots: { transition: SlideTransition }, message: notification.message, autoHideDuration: (_e = notification.duration) !== null && _e !== void 0 ? _e : 2000 }, notification.id));
119
+ }, slots: { transition: GrowTransition }, message: notification.message, autoHideDuration: (_f = notification.duration) !== null && _f !== void 0 ? _f : 2000 }, notification.id));
118
120
  }) })] }));
119
121
  }
120
122
  exports.default = RealtimeProvider;
@@ -12,4 +12,5 @@ export interface NotificationType {
12
12
  vertical: "top" | "bottom";
13
13
  horizontal: "left" | "center" | "right";
14
14
  };
15
+ open?: boolean;
15
16
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tek-wallet",
3
- "version": "0.0.419",
3
+ "version": "0.0.422",
4
4
  "description": "A custom React provider with TypeScript support",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",