tek-wallet 0.0.757 → 0.0.758

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.
@@ -26,8 +26,8 @@ var material_1 = require("@mui/material");
26
26
  var ThemeProvider_1 = require("../../../providers/ThemeProvider");
27
27
  var formatDate_1 = __importDefault(require("../../../utils/formatDate"));
28
28
  function NeonLineChart(_a) {
29
- var _b, _c, _d, _e;
30
- var series = _a.series, categories = _a.categories, _f = _a.showMinMaxValues, showMinMaxValues = _f === void 0 ? false : _f, children = _a.children, sx = _a.sx;
29
+ var _b, _c, _d;
30
+ var series = _a.series, categories = _a.categories, _e = _a.showMinMaxValues, showMinMaxValues = _e === void 0 ? false : _e, children = _a.children, sx = _a.sx;
31
31
  var chartComponentRef = (0, react_1.useRef)(null);
32
32
  var formatValue = (0, useFormatter_1.default)().formatValue;
33
33
  var theme = (0, ThemeProvider_1.useTheme)();
@@ -97,7 +97,7 @@ function NeonLineChart(_a) {
97
97
  var data = (0, react_1.useMemo)(function () {
98
98
  var _a, _b;
99
99
  return (_b = (_a = series === null || series === void 0 ? void 0 : series[0]) === null || _a === void 0 ? void 0 : _a.data) !== null && _b !== void 0 ? _b : [];
100
- }, [((_d = series === null || series === void 0 ? void 0 : series[0]) === null || _d === void 0 ? void 0 : _d.data) && JSON.stringify((_e = series === null || series === void 0 ? void 0 : series[0]) === null || _e === void 0 ? void 0 : _e.data)]);
100
+ }, [(_d = series === null || series === void 0 ? void 0 : series[0]) === null || _d === void 0 ? void 0 : _d.data]);
101
101
  var chartLength = (0, react_1.useMemo)(function () {
102
102
  try {
103
103
  var length_1 = data === null || data === void 0 ? void 0 : data.length;
@@ -124,7 +124,7 @@ function NeonLineChart(_a) {
124
124
  catch (_a) {
125
125
  return -1;
126
126
  }
127
- }, [maxValue]);
127
+ }, [maxValue, data]);
128
128
  var minValue = (0, react_1.useMemo)(function () {
129
129
  try {
130
130
  var min = Math.min.apply(Math, (data !== null && data !== void 0 ? data : []));
@@ -142,7 +142,7 @@ function NeonLineChart(_a) {
142
142
  catch (_a) {
143
143
  return -1;
144
144
  }
145
- }, [minValue]);
145
+ }, [minValue, data]);
146
146
  return ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign({ position: "relative" }, sx), children: [showMinMaxValues && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(framer_motion_1.motion.div, { className: "absolute top-0 w-fit z-50", style: {
147
147
  left: "".concat((maxIndex / chartLength) * 100, "%"),
148
148
  }, initial: {
@@ -159,7 +159,7 @@ function NeonLineChart(_a) {
159
159
  duration: 0.4,
160
160
  ease: "easeInOut",
161
161
  delay: 0.4,
162
- }, children: (0, jsx_runtime_1.jsx)(Text_1.default, { className: "text-ui-text-white text-12 leading-140", children: (0, jsx_runtime_1.jsx)(Formatter_1.default, { value: maxValue }) }) }), (0, jsx_runtime_1.jsx)(framer_motion_1.motion.div, { className: "absolute bottom-0 w-fit z-50", style: {
162
+ }, children: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: __assign({}, theme.mixins.value), children: (0, jsx_runtime_1.jsx)(Formatter_1.default, { value: maxValue }) }) }), (0, jsx_runtime_1.jsx)(framer_motion_1.motion.div, { className: "absolute bottom-0 w-fit z-50", style: {
163
163
  left: "".concat((minIndex / chartLength) * 100, "%"),
164
164
  }, initial: {
165
165
  scale: 0,
@@ -128,7 +128,7 @@ function RealtimeProvider(_a) {
128
128
  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",
129
129
  }, onClose: function () {
130
130
  closeNotification(notification.id);
131
- }, slots: { transition: GrowTransition }, autoHideDuration: (_f = notification.duration) !== null && _f !== void 0 ? _f : 10000, children: (0, jsx_runtime_1.jsx)(material_1.Alert, { icon: false, severity: notification.type, sx: {
131
+ }, slots: { transition: GrowTransition }, autoHideDuration: (_f = notification.duration) !== null && _f !== void 0 ? _f : 5000, children: (0, jsx_runtime_1.jsx)(material_1.Alert, { icon: false, severity: notification.type, sx: {
132
132
  width: "fit-content",
133
133
  borderRadius: theme.mixins.customRadius.r6,
134
134
  mx: "auto",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tek-wallet",
3
- "version": "0.0.757",
3
+ "version": "0.0.758",
4
4
  "description": "A custom React provider with TypeScript support",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",