tek-wallet 0.0.826 → 0.0.827

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.
Files changed (21) hide show
  1. package/dist/components/TekWallet/components/layouts/FullHeightAndScroll/index.d.ts +4 -0
  2. package/dist/components/TekWallet/components/layouts/FullHeightAndScroll/index.js +9 -0
  3. package/dist/components/TekWallet/components/ui/BottomActionLayout/index.js +3 -1
  4. package/dist/components/TekWallet/components/ui/FiatDeposit/index.js +1 -5
  5. package/dist/components/TekWallet/components/views/AssetView/index.js +67 -78
  6. package/dist/components/TekWallet/components/views/ChangePasscodeView/index.js +13 -2
  7. package/dist/components/TekWallet/components/views/SendExternalView/components/Form.js +2 -2
  8. package/dist/components/TekWallet/components/views/SendExternalView/index.js +4 -1
  9. package/dist/components/TekWallet/components/views/SendInternalView/components/Form.js +2 -2
  10. package/dist/components/TekWallet/components/views/SendInternalView/index.js +3 -2
  11. package/dist/components/TekWallet/components/views/SendNftView/components/Form.js +18 -20
  12. package/dist/components/TekWallet/components/views/SwapView/index.js +3 -2
  13. package/package.json +1 -1
  14. package/dist/components/TekWallet/components/ui/ModalSelectToken/index.d.ts +0 -9
  15. package/dist/components/TekWallet/components/ui/ModalSelectToken/index.js +0 -127
  16. package/dist/components/TekWallet/components/ui/ReceiveHistory/ReceiveCardHistory.d.ts +0 -11
  17. package/dist/components/TekWallet/components/ui/ReceiveHistory/ReceiveCardHistory.js +0 -77
  18. package/dist/components/TekWallet/components/ui/ReceiveHistory/ReceiveHistoryDetails.d.ts +0 -8
  19. package/dist/components/TekWallet/components/ui/ReceiveHistory/ReceiveHistoryDetails.js +0 -115
  20. package/dist/components/TekWallet/components/ui/ReceiveHistory/index.d.ts +0 -9
  21. package/dist/components/TekWallet/components/ui/ReceiveHistory/index.js +0 -447
@@ -1,127 +0,0 @@
1
- "use strict";
2
- var __assign = (this && this.__assign) || function () {
3
- __assign = Object.assign || function(t) {
4
- for (var s, i = 1, n = arguments.length; i < n; i++) {
5
- s = arguments[i];
6
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
- t[p] = s[p];
8
- }
9
- return t;
10
- };
11
- return __assign.apply(this, arguments);
12
- };
13
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- var desc = Object.getOwnPropertyDescriptor(m, k);
16
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
17
- desc = { enumerable: true, get: function() { return m[k]; } };
18
- }
19
- Object.defineProperty(o, k2, desc);
20
- }) : (function(o, m, k, k2) {
21
- if (k2 === undefined) k2 = k;
22
- o[k2] = m[k];
23
- }));
24
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
25
- Object.defineProperty(o, "default", { enumerable: true, value: v });
26
- }) : function(o, v) {
27
- o["default"] = v;
28
- });
29
- var __importStar = (this && this.__importStar) || (function () {
30
- var ownKeys = function(o) {
31
- ownKeys = Object.getOwnPropertyNames || function (o) {
32
- var ar = [];
33
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
34
- return ar;
35
- };
36
- return ownKeys(o);
37
- };
38
- return function (mod) {
39
- if (mod && mod.__esModule) return mod;
40
- var result = {};
41
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
42
- __setModuleDefault(result, mod);
43
- return result;
44
- };
45
- })();
46
- var __importDefault = (this && this.__importDefault) || function (mod) {
47
- return (mod && mod.__esModule) ? mod : { "default": mod };
48
- };
49
- Object.defineProperty(exports, "__esModule", { value: true });
50
- var jsx_runtime_1 = require("react/jsx-runtime");
51
- var material_1 = require("@mui/material");
52
- var react_1 = require("react");
53
- var useBoolean_1 = require("../../../hooks/useBoolean");
54
- var CardToken_1 = __importDefault(require("../CardToken"));
55
- var useWallet_1 = __importDefault(require("../../../hooks/useWallet"));
56
- var PageHeader_1 = __importDefault(require("../PageHeader"));
57
- var useCustomRouter_1 = __importDefault(require("../../../hooks/useCustomRouter"));
58
- var getIcon_1 = __importDefault(require("../../../utils/getIcon"));
59
- var DrawerDrag_1 = __importStar(require("../DrawerDrag"));
60
- var Icon_1 = __importDefault(require("../Icon"));
61
- var Text_1 = __importDefault(require("../Text"));
62
- var mui_1 = require("../../../theme/mui");
63
- var ModalSelectToken = function (props) {
64
- var setSwapToken = props.setSwapToken;
65
- var selectTokenForm = (0, useBoolean_1.useBoolean)("selectTokenForm");
66
- var selectTokenTo = (0, useBoolean_1.useBoolean)("selectTokenTo");
67
- var open = selectTokenForm.value ? selectTokenForm.value : selectTokenTo.value;
68
- var onOpen = selectTokenForm.value ? selectTokenForm.setTrue : selectTokenTo.setTrue;
69
- var onClose = selectTokenForm.value ? selectTokenForm.setFalse : selectTokenTo.setFalse;
70
- var _a = (0, useWallet_1.default)(), fromTokens = _a.fromTokens, updateSwapTokens = _a.updateSwapTokens;
71
- var theme = (0, mui_1.useTheme)();
72
- var router = (0, useCustomRouter_1.default)();
73
- (0, react_1.useEffect)(function () {
74
- if (fromTokens && fromTokens.length > 0 && !props.token && setSwapToken) {
75
- setSwapToken(fromTokens[0]);
76
- }
77
- }, [fromTokens, props.token, setSwapToken, updateSwapTokens]);
78
- var handleSelectToken = function (token) {
79
- if (setSwapToken) {
80
- setSwapToken(token);
81
- }
82
- onClose();
83
- };
84
- var handleOutputToken = function (output) {
85
- if (props.setOutputToken) {
86
- props.setOutputToken(output);
87
- }
88
- onClose();
89
- };
90
- return ((0, jsx_runtime_1.jsx)(DrawerDrag_1.default, { sx: {
91
- "& .MuiDrawer-paper": {
92
- width: "100%",
93
- },
94
- }, className: "!bg-white !rounded-none !size-full", anchor: DrawerDrag_1.DRAWER_DIRECTION.RIGHT, open: open, onClose: onClose, onOpen: onOpen, title: (0, jsx_runtime_1.jsx)(material_1.Box, { children: (0, jsx_runtime_1.jsx)(PageHeader_1.default, { overrideBack: onClose, onClick: onClose, title: selectTokenForm.value === true ? "Select from token" : "Select to token", children: (0, jsx_runtime_1.jsxs)(material_1.Box, { className: "flex gap-1 items-center ml-auto", children: [(0, jsx_runtime_1.jsx)(Icon_1.default, { onClick: function () { return router.push("/help"); }, src: (0, getIcon_1.default)("help") }), (0, jsx_runtime_1.jsx)(material_1.Divider, { orientation: "vertical", sx: {
95
- height: "15px",
96
- width: "1px",
97
- backgroundColor: theme.palette.divider,
98
- marginLeft: theme.styleMixins.customMargin.m4,
99
- marginRight: theme.styleMixins.customMargin.m4,
100
- } }), (0, jsx_runtime_1.jsx)(Icon_1.default, { onClick: function () { return router.push("/history"); }, src: (0, getIcon_1.default)("history") })] }) }) }), content: (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign({}, theme.styleMixins.pagePadding), children: [(0, jsx_runtime_1.jsx)(material_1.InputBase, { startAdornment: (0, jsx_runtime_1.jsx)(material_1.InputAdornment, { className: "size-5 text-black", position: "start", children: (0, jsx_runtime_1.jsx)(Icon_1.default, { className: "size-5", src: (0, getIcon_1.default)("search") }) }), placeholder: "Search", sx: {
101
- "input::placeholder": {
102
- fontSize: theme.typography.fontSize12,
103
- color: theme.palette.text.primary,
104
- fontWeight: theme.typography.fontWeight500,
105
- pl: theme.styleMixins.customPadding.p4,
106
- },
107
- }, className: "w-full flex items-center py-1 px-2 rounded-12 border border-".concat(theme.palette.divider, " bg-white text-black") }), (0, jsx_runtime_1.jsxs)(material_1.Box, { className: "py-4 mt-3 h-[50dvh] space-y-3", children: [(0, jsx_runtime_1.jsxs)(material_1.Box, { className: "flex justify-between items-center", children: [(0, jsx_runtime_1.jsxs)(material_1.Box, { className: "flex items-center gap-1", children: [(0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
108
- color: theme.palette.text.secondary,
109
- fontSize: theme.typography.fontSize12,
110
- fontWeight: theme.typography.fontWeight600,
111
- }, children: "Token" }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign({}, theme.styleMixins.column), className: "items-center gap-0.5", children: [(0, jsx_runtime_1.jsx)(Icon_1.default, { src: (0, getIcon_1.default)("arrow_drop_up") }), (0, jsx_runtime_1.jsx)(Icon_1.default, { src: (0, getIcon_1.default)("arrow_drop_down") })] })] }), (0, jsx_runtime_1.jsxs)(material_1.Box, { className: "flex items-center gap-1", children: [(0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
112
- color: theme.palette.text.secondary,
113
- fontSize: theme.typography.fontSize12,
114
- fontWeight: theme.typography.fontWeight600,
115
- }, children: "Balance" }), (0, jsx_runtime_1.jsxs)(material_1.Box, { className: "flex items-center gap-0.5 flex-col", children: [(0, jsx_runtime_1.jsx)(Icon_1.default, { src: (0, getIcon_1.default)("arrow_drop_up") }), (0, jsx_runtime_1.jsx)(Icon_1.default, { src: (0, getIcon_1.default)("arrow_drop_down") })] })] })] }), (0, jsx_runtime_1.jsx)(material_1.Box, { className: "space-y-3", children: selectTokenForm.value
116
- ? fromTokens === null || fromTokens === void 0 ? void 0 : fromTokens.map(function (token) {
117
- var _a;
118
- return ((0, jsx_runtime_1.jsx)(material_1.Box, { onClick: function () { return handleSelectToken(token); }, children: (0, jsx_runtime_1.jsx)(CardToken_1.default, { icon: token.link, symbol: token.full_name, price: "".concat(Number(token.balance).toFixed(2)), balance: token.name, rate: String(Number(token.usd_rate)), isActive: token.id === ((_a = props.token) === null || _a === void 0 ? void 0 : _a.id) }, token.id) }, token.id));
119
- })
120
- : selectTokenTo.value &&
121
- props.token &&
122
- props.token.outputs.map(function (output) {
123
- var _a;
124
- return ((0, jsx_runtime_1.jsx)(material_1.Box, { onClick: function () { return handleOutputToken(output); }, children: (0, jsx_runtime_1.jsx)(CardToken_1.default, { icon: output.link, symbol: output.full_name, price: "".concat(Number(output.balance).toFixed(2)), balance: output.name, rate: String(Number(output.usd_rate)), isActive: output.id === ((_a = props.outputToken) === null || _a === void 0 ? void 0 : _a.id) }, output.id) }, output.id));
125
- }) })] })] }) }));
126
- };
127
- exports.default = ModalSelectToken;
@@ -1,11 +0,0 @@
1
- interface ReceiveCardHistory {
2
- className?: string;
3
- amount?: number;
4
- toAddress?: string;
5
- date?: string;
6
- status?: string;
7
- currencySlug?: string;
8
- network?: string;
9
- }
10
- declare const ReceiveCardHistory: ({ toAddress, date, amount, currencySlug, network, status, }: ReceiveCardHistory) => import("react/jsx-runtime").JSX.Element;
11
- export default ReceiveCardHistory;
@@ -1,77 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- var jsx_runtime_1 = require("react/jsx-runtime");
7
- var mui_1 = require("../../../theme/mui");
8
- var Text_1 = __importDefault(require("../Text"));
9
- var Column_1 = __importDefault(require("../Column"));
10
- var Row_1 = __importDefault(require("../Row"));
11
- var InlineTitleValue_1 = __importDefault(require("../InlineTitleValue"));
12
- var CopyTextComponent_1 = __importDefault(require("../CopyTextComponent"));
13
- var safeText_1 = require("../../../utils/safeText");
14
- var number_extension_1 = require("../../../utils/number.extension");
15
- var material_1 = require("@mui/material");
16
- var SvgPath_1 = require("../SvgPath");
17
- var formatDate_1 = require("../../../utils/formatDate");
18
- var ReceiveCardHistory = function (_a) {
19
- var toAddress = _a.toAddress, date = _a.date, amount = _a.amount, currencySlug = _a.currencySlug, network = _a.network, status = _a.status;
20
- var theme = (0, mui_1.useTheme)();
21
- var getStatusColor = function (status) {
22
- switch (status) {
23
- case "success":
24
- return theme.palette.success.main;
25
- case "failed":
26
- return theme.palette.error.main;
27
- case "processing":
28
- return theme.palette.warning.main;
29
- default:
30
- return theme.palette.text.secondary;
31
- }
32
- };
33
- return ((0, jsx_runtime_1.jsxs)(Column_1.default, { sx: {
34
- gap: theme.styleMixins.gaps.g2,
35
- }, children: [(0, jsx_runtime_1.jsx)(Row_1.default, { sx: { justifyContent: "space-between" }, children: (0, jsx_runtime_1.jsxs)(Column_1.default, { sx: { gap: theme.styleMixins.gaps.g1 }, children: [(0, jsx_runtime_1.jsxs)(Text_1.default, { sx: {
36
- fontWeight: 700,
37
- fontSize: "1rem",
38
- }, children: [(0, number_extension_1.formatCurrencyNumber)(Number(amount !== null && amount !== void 0 ? amount : 0)), " ", currencySlug === null || currencySlug === void 0 ? void 0 : currencySlug.toUpperCase()] }), (0, jsx_runtime_1.jsx)(material_1.Box, { sx: {
39
- backgroundColor: getStatusColor(status !== null && status !== void 0 ? status : ""),
40
- borderRadius: theme.styleMixins.customRadius.r8,
41
- padding: theme.styleMixins.customPadding.p4,
42
- width: "fit-content",
43
- display: "flex",
44
- alignItems: "center",
45
- justifyContent: "center",
46
- }, children: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: { fontWeight: 500, fontSize: "0.625rem" }, children: (0, safeText_1.firstLetterToUpperCase)(status !== null && status !== void 0 ? status : "unknown") }) })] }) }), (0, jsx_runtime_1.jsxs)(Column_1.default, { sx: { gap: theme.styleMixins.gaps.g2, paddingTop: theme.styleMixins.customPadding.p4 }, children: [(0, jsx_runtime_1.jsx)(InlineTitleValue_1.default, { title: "To address:", titleStyle: {
47
- fontWeight: 500,
48
- fontSize: "0.813rem",
49
- color: theme.palette.text.secondary,
50
- }, value: (0, jsx_runtime_1.jsx)(CopyTextComponent_1.default, { value: (0, safeText_1.safeText)(toAddress !== null && toAddress !== void 0 ? toAddress : "", {
51
- isShort: true,
52
- }), children: (0, jsx_runtime_1.jsxs)(Row_1.default, { sx: {
53
- gap: theme.styleMixins.gaps.g1,
54
- justifyContent: "space-between",
55
- width: "100%",
56
- }, children: [(0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
57
- whiteSpace: "nowrap",
58
- fontWeight: 500,
59
- fontSize: "0.813rem",
60
- }, children: (0, safeText_1.safeText)(toAddress !== null && toAddress !== void 0 ? toAddress : "", {
61
- isShort: true,
62
- }) }), (0, jsx_runtime_1.jsx)(material_1.SvgIcon, { sx: { width: 16, height: 16 }, children: SvgPath_1.IC_COPY })] }) }) }), (0, jsx_runtime_1.jsx)(InlineTitleValue_1.default, { title: "Network:", titleStyle: {
63
- color: theme.palette.text.secondary,
64
- fontWeight: 500,
65
- fontSize: "0.813rem",
66
- }, value: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
67
- color: theme.palette.text.secondary,
68
- whiteSpace: "nowrap",
69
- fontWeight: 500,
70
- fontSize: "0.813rem",
71
- }, children: network === null || network === void 0 ? void 0 : network.toUpperCase() }) }), (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
72
- color: theme.palette.text.secondary,
73
- fontWeight: 500,
74
- fontSize: "0.813rem",
75
- }, children: (0, formatDate_1.customFormatDate)(date !== null && date !== void 0 ? date : "", { format: formatDate_1.DateFormat.MMM_DD_YYYY_HH_MM_SS }) })] })] }));
76
- };
77
- exports.default = ReceiveCardHistory;
@@ -1,8 +0,0 @@
1
- import React from "react";
2
- import { SwapResponse } from "../../../services/axios/swap-service/type";
3
- interface ReceiveHistoryDetailsProps {
4
- onClose?: () => void;
5
- receiveData?: SwapResponse;
6
- }
7
- declare const ReceiveHistoryDetails: React.FC<ReceiveHistoryDetailsProps>;
8
- export default ReceiveHistoryDetails;
@@ -1,115 +0,0 @@
1
- "use strict";
2
- var __assign = (this && this.__assign) || function () {
3
- __assign = Object.assign || function(t) {
4
- for (var s, i = 1, n = arguments.length; i < n; i++) {
5
- s = arguments[i];
6
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
- t[p] = s[p];
8
- }
9
- return t;
10
- };
11
- return __assign.apply(this, arguments);
12
- };
13
- var __importDefault = (this && this.__importDefault) || function (mod) {
14
- return (mod && mod.__esModule) ? mod : { "default": mod };
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- var jsx_runtime_1 = require("react/jsx-runtime");
18
- var react_1 = require("react");
19
- var useWallet_1 = __importDefault(require("../../../hooks/useWallet"));
20
- var mui_1 = require("../../../theme/mui");
21
- var ChildPageLayout_1 = __importDefault(require("../../layouts/ChildPageLayout"));
22
- var Button_1 = __importDefault(require("../Button"));
23
- var Text_1 = __importDefault(require("../Text"));
24
- var material_1 = require("@mui/material");
25
- var Icon_1 = __importDefault(require("../Icon"));
26
- var getIcon_1 = __importDefault(require("../../../utils/getIcon"));
27
- var LineValue_1 = __importDefault(require("../LineValue"));
28
- var formatDate_1 = __importDefault(require("../../../utils/formatDate"));
29
- var roundToTwoSignificantDecimals_1 = __importDefault(require("../../../utils/roundToTwoSignificantDecimals"));
30
- var ReceiveHistoryDetails = function (_a) {
31
- var _b, _c, _d;
32
- var onClose = _a.onClose, swapData = _a.receiveData;
33
- var transaction = (0, useWallet_1.default)().transaction;
34
- var theme = (0, mui_1.useTheme)();
35
- var resultData = transaction || (swapData === null || swapData === void 0 ? void 0 : swapData.data);
36
- var feeInfo = (0, react_1.useMemo)(function () {
37
- var _a, _b;
38
- return ((_b = (_a = resultData === null || resultData === void 0 ? void 0 : resultData.fee_info) === null || _a === void 0 ? void 0 : _a.fee_detail) === null || _b === void 0 ? void 0 : _b.map(function (item) { return item === null || item === void 0 ? void 0 : item.currency; })) || [];
39
- }, [resultData]);
40
- var getOutputs = feeInfo === null || feeInfo === void 0 ? void 0 : feeInfo.map(function (item) { return item === null || item === void 0 ? void 0 : item.outputs; });
41
- var getDetailOutputs = ((_b = getOutputs === null || getOutputs === void 0 ? void 0 : getOutputs[0]) === null || _b === void 0 ? void 0 : _b.map(function (item) { return item; })) || [];
42
- var getInfoDetailOutputs = (0, react_1.useMemo)(function () {
43
- return (getDetailOutputs === null || getDetailOutputs === void 0 ? void 0 : getDetailOutputs[0]) || {};
44
- }, [getDetailOutputs]);
45
- return ((0, jsx_runtime_1.jsx)(ChildPageLayout_1.default, { sx: __assign({ color: theme.palette.text.primary, width: "100%" }, theme.styleMixins.pagePadding), footer: (0, jsx_runtime_1.jsx)(material_1.Box, { sx: {
46
- px: theme.styleMixins.customPadding.p12,
47
- position: "relative",
48
- bottom: theme.typography.fontSize24,
49
- }, children: (resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "processing" ||
50
- (resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "failed" ? ((0, jsx_runtime_1.jsx)(Button_1.default.Primary, { onClick: onClose, sx: __assign(__assign({ gap: theme.styleMixins.gaps.g4 }, theme.styleMixins.row), { color: theme.palette.text.secondary, borderRadius: theme.styleMixins.customRadius.r12, height: "40px" }), fullWidth: true, children: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
51
- fontSize: theme.typography.fontSize12,
52
- fontWeight: theme.typography.fontWeight600,
53
- leading: theme.typography.leading160,
54
- textTransform: "none",
55
- color: theme.palette.secondary.main,
56
- }, children: "Close" }) })) : ((resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "success" && ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.row), { gap: theme.styleMixins.gaps.g8, justifyContent: "center" }), children: [(0, jsx_runtime_1.jsx)(Button_1.default.Secondary, { onClick: onClose, sx: __assign(__assign({ gap: theme.styleMixins.gaps.g4 }, theme.styleMixins.row), { borderRadius: theme.styleMixins.customRadius.r12, borderColor: theme.palette.primary.main, backgroundColor: "transparent", maxWidth: "100%", height: "40px" }), fullWidth: true, children: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
57
- fontSize: theme.typography.fontSize13,
58
- fontWeight: theme.typography.fontWeight600,
59
- color: theme.palette.primary.main,
60
- leading: theme.typography.leading160,
61
- textTransform: "none",
62
- }, children: "Close" }) }), (0, jsx_runtime_1.jsx)(Button_1.default.Primary, { onClick: onClose, sx: __assign(__assign({ gap: theme.styleMixins.gaps.g4 }, theme.styleMixins.row), { color: theme.palette.text.secondary, borderRadius: theme.styleMixins.customRadius.r12, maxWidth: "100%", height: "40px" }), fullWidth: true, children: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
63
- fontSize: theme.typography.fontSize13,
64
- fontWeight: theme.typography.fontWeight600,
65
- leading: theme.typography.leading160,
66
- textTransform: "none",
67
- color: theme.palette.secondary.main,
68
- }, children: "View asset" }) })] }))) }), children: (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({ width: "100%" }, theme.styleMixins.column), { top: 0, transform: "translateY(30%)", gap: theme.styleMixins.gaps.g12, backgroundColor: theme.palette.background.tertiary, borderRadius: theme.styleMixins.customRadius.r16, padding: theme.styleMixins.customPadding.p16, paddingTop: "80px", alignItems: "flex-start", position: "relative", marginTop: "75px" }), children: [(0, jsx_runtime_1.jsx)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.center), { top: 0, width: "fit-content", height: "fit-content", borderRadius: theme.styleMixins.customRadius.r12, padding: theme.styleMixins.customPadding.p8 }), children: (0, jsx_runtime_1.jsx)(Icon_1.default, { width: 100, height: 100, src: (0, getIcon_1.default)((resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "success"
69
- ? "success"
70
- : (resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "failed"
71
- ? "failed"
72
- : (resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status) == "processing"
73
- ? "processing"
74
- : "") }) }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.column), { mt: theme.styleMixins.customMargin.m8, textAlign: "center" }), children: [(0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
75
- color: theme.palette.text.secondary,
76
- fontSize: theme.typography.fontSize14,
77
- fontWeight: theme.typography.fontWeight400,
78
- }, children: "Swapping Token" }), (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
79
- fontSize: theme.typography.fontSize24,
80
- fontWeight: theme.typography.fontWeight600,
81
- textTransform: "capitalize",
82
- }, children: resultData === null || resultData === void 0 ? void 0 : resultData.transaction_status }), (0, jsx_runtime_1.jsx)(material_1.Divider, { sx: {
83
- width: "100%",
84
- color: theme.palette.text.secondary,
85
- mt: theme.styleMixins.customMargin.m12,
86
- } }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.row), { justifyContent: "space-between", mt: theme.styleMixins.customMargin.m16 }), children: [(0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.row), { gap: theme.styleMixins.gaps.g8 }), children: [(0, jsx_runtime_1.jsx)(Icon_1.default, { src: (_c = resultData === null || resultData === void 0 ? void 0 : resultData.currency_data) === null || _c === void 0 ? void 0 : _c.link, width: 20, height: 20, className: "rounded-full" }), (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
87
- fontSize: theme.typography.fontSize14,
88
- fontWeight: theme.typography.fontWeight700,
89
- }, children: resultData === null || resultData === void 0 ? void 0 : resultData.amount })] }), (0, jsx_runtime_1.jsx)(Icon_1.default, { src: (0, getIcon_1.default)("swap_horizontal"), width: 20, height: 20 }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: __assign(__assign({}, theme.styleMixins.row), { gap: theme.styleMixins.gaps.g8 }), children: [(0, jsx_runtime_1.jsx)(Icon_1.default, { src: getInfoDetailOutputs === null || getInfoDetailOutputs === void 0 ? void 0 : getInfoDetailOutputs.link, width: 20, height: 20, className: "rounded-full" }), (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
90
- fontSize: theme.typography.fontSize14,
91
- fontWeight: theme.typography.fontWeight700,
92
- }, children: (0, roundToTwoSignificantDecimals_1.default)((resultData === null || resultData === void 0 ? void 0 : resultData.amount) * (getInfoDetailOutputs === null || getInfoDetailOutputs === void 0 ? void 0 : getInfoDetailOutputs.swap_amount)) })] })] }), (0, jsx_runtime_1.jsx)(material_1.Divider, { sx: {
93
- width: "100%",
94
- color: theme.palette.text.secondary,
95
- mt: theme.styleMixins.customMargin.m12,
96
- } }), (0, jsx_runtime_1.jsx)(LineValue_1.default, { sx: {
97
- mt: theme.styleMixins.customMargin.m16,
98
- mb: theme.styleMixins.customMargin.m16,
99
- }, field: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
100
- fontSize: theme.typography.fontSize12,
101
- color: theme.palette.text.primary,
102
- }, children: "Price" }), value: (0, jsx_runtime_1.jsxs)(Text_1.default, { sx: {
103
- fontSize: theme.typography.fontSize14,
104
- fontWeight: theme.typography.fontWeight700,
105
- ml: theme.styleMixins.customMargin.m8,
106
- }, children: ["1 ", (_d = resultData === null || resultData === void 0 ? void 0 : resultData.currency_data) === null || _d === void 0 ? void 0 : _d.full_name, " ~ ", getInfoDetailOutputs === null || getInfoDetailOutputs === void 0 ? void 0 : getInfoDetailOutputs.swap_amount, " ", getInfoDetailOutputs === null || getInfoDetailOutputs === void 0 ? void 0 : getInfoDetailOutputs.full_name] }) }), (0, jsx_runtime_1.jsx)(LineValue_1.default, { field: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
107
- fontSize: theme.typography.fontSize12,
108
- color: theme.palette.text.primary,
109
- }, children: "Date time" }), value: (0, jsx_runtime_1.jsx)(Text_1.default, { sx: {
110
- fontSize: theme.typography.fontSize14,
111
- fontWeight: theme.typography.fontWeight700,
112
- ml: theme.styleMixins.customMargin.m8,
113
- }, children: (0, formatDate_1.default)(resultData === null || resultData === void 0 ? void 0 : resultData.date_created) }) })] })] }) }));
114
- };
115
- exports.default = ReceiveHistoryDetails;
@@ -1,9 +0,0 @@
1
- interface ReceiveHistoryProps {
2
- onClose?: () => void;
3
- open?: boolean;
4
- }
5
- export interface ReceiveHistoryRef {
6
- resetStatus: () => void;
7
- }
8
- declare const ReceiveHistory: (props: ReceiveHistoryProps) => import("react/jsx-runtime").JSX.Element;
9
- export default ReceiveHistory;