@matchain/matchid-sdk-react 0.1.53-alpha.1 → 0.1.53-alpha.3
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/assets/icon/index.d.mts +4 -2
- package/dist/assets/icon/index.d.ts +4 -2
- package/dist/assets/icon/index.js +19 -0
- package/dist/assets/icon/index.js.map +1 -1
- package/dist/assets/icon/index.mjs +3 -1
- package/dist/{chunk-LHNKZISB.mjs → chunk-3USZ4ZZY.mjs} +20 -2
- package/dist/chunk-3USZ4ZZY.mjs.map +1 -0
- package/dist/{chunk-2DVC6WCN.mjs → chunk-3YF3P77J.mjs} +270 -419
- package/dist/chunk-3YF3P77J.mjs.map +1 -0
- package/dist/{chunk-6QTW3KXN.mjs → chunk-4EVF2PXX.mjs} +2 -2
- package/dist/{chunk-HLUFAIFV.mjs → chunk-OCQ2AIM3.mjs} +7 -2
- package/dist/{chunk-HLUFAIFV.mjs.map → chunk-OCQ2AIM3.mjs.map} +1 -1
- package/dist/{chunk-FB5MHLWX.mjs → chunk-V2S54LGG.mjs} +2 -2
- package/dist/components/index.d.mts +3 -3
- package/dist/components/index.d.ts +3 -3
- package/dist/components/index.js +396 -511
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +5 -7
- package/dist/hooks/api/index.d.mts +2 -2
- package/dist/hooks/api/index.d.ts +2 -2
- package/dist/hooks/api/index.js +89 -133
- package/dist/hooks/api/index.js.map +1 -1
- package/dist/hooks/api/index.mjs +5 -5
- package/dist/hooks/index.d.mts +2 -2
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/index.js +207 -264
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +5 -5
- package/dist/{index-DvM6x6e6.d.ts → index-BKHtf1Tu.d.ts} +1 -1
- package/dist/{index-BDoEk1EK.d.ts → index-BSUoL5Jo.d.mts} +4 -11
- package/dist/{index-XzSw1Bym.d.mts → index-BVO4Bt59.d.ts} +4 -11
- package/dist/{index-k2Uf0F94.d.ts → index-CcN5ls1U.d.ts} +1 -1
- package/dist/{index-BUj9mOrS.d.ts → index-Cul4qlZl.d.ts} +1 -1
- package/dist/{index-D5OzNRfu.d.mts → index-CvVl_Xw1.d.mts} +2 -2
- package/dist/{index-Bmir-Wor.d.mts → index-DXRsJY9h.d.mts} +1 -1
- package/dist/{index-X_fw5wX_.d.ts → index-DgwlV4ve.d.ts} +3 -3
- package/dist/{index-B_o9HBS1.d.mts → index-DrEKzXYX.d.mts} +1 -1
- package/dist/{index-B-QfwtE5.d.mts → index-EPwrSSOz.d.mts} +3 -3
- package/dist/{index-CDqIk5k2.d.mts → index-ba3VTkaV.d.mts} +1 -1
- package/dist/{index-DMUZQqNB.d.ts → index-lKJjj0w4.d.ts} +2 -2
- package/dist/index.d.mts +7 -8
- package/dist/index.d.ts +7 -8
- package/dist/index.js +509 -601
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +12 -12
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/{types-Dd_ExpLx.d.mts → types-Bgd3Ac92.d.mts} +1 -2
- package/dist/{types-Dd_ExpLx.d.ts → types-Bgd3Ac92.d.ts} +1 -2
- package/dist/ui/index.d.mts +3 -3
- package/dist/ui/index.d.ts +3 -3
- package/dist/ui/index.js +62 -59
- package/dist/ui/index.js.map +1 -1
- package/dist/ui/index.mjs +2 -2
- package/dist/utils/index.d.mts +2 -1
- package/dist/utils/index.d.ts +2 -1
- package/dist/utils/index.js +6 -0
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/index.mjs +3 -1
- package/example/dist/assets/ccip-nxE3Zma4.js +1 -0
- package/example/dist/assets/index-BFAv3rdU.css +1 -0
- package/example/dist/assets/index-DMWWRDPI.js +1658 -0
- package/example/dist/index.html +2 -2
- package/package.json +1 -5
- package/dist/chunk-2DVC6WCN.mjs.map +0 -1
- package/dist/chunk-LHNKZISB.mjs.map +0 -1
- package/example/dist/assets/TransportWebHID-BEu7tC0r.js +0 -1
- package/example/dist/assets/bignumber-iG7K-qxw.js +0 -10
- package/example/dist/assets/ccip-a6wQ1Vcb.js +0 -1
- package/example/dist/assets/draggabilly-CRYR_S0q.js +0 -14
- package/example/dist/assets/index--dp9m9Ep.js +0 -1
- package/example/dist/assets/index-BDTHolFv.js +0 -569
- package/example/dist/assets/index-BZl59qLb.js +0 -179
- package/example/dist/assets/index-BmMbYNHO.js +0 -303
- package/example/dist/assets/index-C7cxVRDF.js +0 -1677
- package/example/dist/assets/index-CJk171Yb.js +0 -1
- package/example/dist/assets/index-CQiBesAa.js +0 -3
- package/example/dist/assets/index-D62loNA9.js +0 -3
- package/example/dist/assets/index-DqyX3FG6.js +0 -1
- package/example/dist/assets/index-Gy3FXGhr.css +0 -1
- package/example/dist/assets/inherits_browser-BlmhoU4v.js +0 -1
- package/example/dist/assets/solanaEmbed.esm-Djn-u4Vn.js +0 -38
- /package/dist/{chunk-6QTW3KXN.mjs.map → chunk-4EVF2PXX.mjs.map} +0 -0
- /package/dist/{chunk-FB5MHLWX.mjs.map → chunk-V2S54LGG.mjs.map} +0 -0
package/dist/components/index.js
CHANGED
|
@@ -43,7 +43,6 @@ __export(components_exports, {
|
|
|
43
43
|
ModalWithHeader: () => ModalWithHeader,
|
|
44
44
|
Overlay: () => Overlay,
|
|
45
45
|
Popover: () => Popover,
|
|
46
|
-
SOLModal: () => SOLModal,
|
|
47
46
|
TONModal: () => TONModal,
|
|
48
47
|
TRONModal: () => TRONModal,
|
|
49
48
|
TokenDetail: () => TokenDetail,
|
|
@@ -1184,6 +1183,23 @@ function ArrowSendIcon({
|
|
|
1184
1183
|
) });
|
|
1185
1184
|
}
|
|
1186
1185
|
|
|
1186
|
+
// src/assets/icon/PhantomIcon.tsx
|
|
1187
|
+
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
1188
|
+
function PhantomIcon({
|
|
1189
|
+
size = 128,
|
|
1190
|
+
...props
|
|
1191
|
+
}) {
|
|
1192
|
+
return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("svg", { width: size, height: size, ...props, viewBox: "0 0 128 128", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
|
|
1193
|
+
"path",
|
|
1194
|
+
{
|
|
1195
|
+
fill: "#ab9ff2",
|
|
1196
|
+
d: "m53.520552,86.603299c-5.9423,9.106 -15.8999,20.63 -29.1497,20.63c-6.2636,0 -12.2864,-2.578 -12.2866,-13.779c-0.0005,-28.5271 38.946,-72.687 75.0825,-72.6876c20.557,-0.0004 28.749,14.2625 28.749,30.4597c0,20.7903 -13.491,44.5629 -26.901,44.5629c-4.256,0 -6.344,-2.337 -6.344,-6.043c0,-0.967 0.16,-2.015 0.482,-3.143c-4.578,7.816 -13.411,15.07 -21.6822,15.07c-6.0227,0 -9.074,-3.788 -9.0741,-9.107c0,-1.934 0.4015,-3.948 1.1241,-5.963zm26.8222,-43.9027c-3.271,0.0058 -5.501,2.7849 -5.494,6.7495c0.007,3.9646 2.247,6.8152 5.518,6.8095c3.192,-0.0057 5.421,-2.8641 5.414,-6.8288c-0.007,-3.9646 -2.246,-6.7358 -5.438,-6.7302zm17.351,-0.0189c-3.271,0.0058 -5.501,2.7849 -5.494,6.7495c0.007,3.9646 2.246,6.8152 5.518,6.8095c3.192,-0.0056 5.421,-2.8641 5.414,-6.8288c-0.007,-3.9646 -2.246,-6.7358 -5.438,-6.7302z",
|
|
1197
|
+
clipRule: "evenodd",
|
|
1198
|
+
fillRule: "evenodd"
|
|
1199
|
+
}
|
|
1200
|
+
) });
|
|
1201
|
+
}
|
|
1202
|
+
|
|
1187
1203
|
// src/hooks/useLayout.tsx
|
|
1188
1204
|
var import_react = require("react");
|
|
1189
1205
|
function useDownMd() {
|
|
@@ -1202,7 +1218,7 @@ function useDownMd() {
|
|
|
1202
1218
|
|
|
1203
1219
|
// src/ui/Overlay/index.tsx
|
|
1204
1220
|
var import_react2 = require("react");
|
|
1205
|
-
var
|
|
1221
|
+
var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
1206
1222
|
function Overlay({
|
|
1207
1223
|
isOpen = false,
|
|
1208
1224
|
children,
|
|
@@ -1218,7 +1234,7 @@ function Overlay({
|
|
|
1218
1234
|
document.body.style.overflow = "";
|
|
1219
1235
|
};
|
|
1220
1236
|
}, [isOpen]);
|
|
1221
|
-
return isOpen ? /* @__PURE__ */ (0,
|
|
1237
|
+
return isOpen ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
1222
1238
|
"div",
|
|
1223
1239
|
{
|
|
1224
1240
|
className: "matchid-overlay",
|
|
@@ -1227,11 +1243,11 @@ function Overlay({
|
|
|
1227
1243
|
},
|
|
1228
1244
|
children
|
|
1229
1245
|
}
|
|
1230
|
-
) : /* @__PURE__ */ (0,
|
|
1246
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_jsx_runtime50.Fragment, {});
|
|
1231
1247
|
}
|
|
1232
1248
|
|
|
1233
1249
|
// src/ui/Modal/index.tsx
|
|
1234
|
-
var
|
|
1250
|
+
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
1235
1251
|
function Modal({
|
|
1236
1252
|
children,
|
|
1237
1253
|
isOpen,
|
|
@@ -1239,10 +1255,10 @@ function Modal({
|
|
|
1239
1255
|
zIndex = 100,
|
|
1240
1256
|
className = ""
|
|
1241
1257
|
}) {
|
|
1242
|
-
return /* @__PURE__ */ (0,
|
|
1258
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Overlay, { isOpen, zIndex, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: `matchid-modal ${className}`, style: {
|
|
1243
1259
|
width
|
|
1244
1260
|
}, children: [
|
|
1245
|
-
/* @__PURE__ */ (0,
|
|
1261
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "matchid-modal-mobile-header" }),
|
|
1246
1262
|
children
|
|
1247
1263
|
] }) });
|
|
1248
1264
|
}
|
|
@@ -1256,13 +1272,13 @@ function ModalWithHeader({
|
|
|
1256
1272
|
...props
|
|
1257
1273
|
}) {
|
|
1258
1274
|
const isDownMd = useDownMd();
|
|
1259
|
-
return /* @__PURE__ */ (0,
|
|
1260
|
-
/* @__PURE__ */ (0,
|
|
1261
|
-
/* @__PURE__ */ (0,
|
|
1262
|
-
onBack && /* @__PURE__ */ (0,
|
|
1263
|
-
/* @__PURE__ */ (0,
|
|
1275
|
+
return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(Modal, { ...props, children: [
|
|
1276
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: `matchid-modal-header ${showBorder ? "matchid-modal-header-border" : ""}`, children: [
|
|
1277
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "matchid-modal-header-content", children: [
|
|
1278
|
+
onBack && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(ArrowLeftIcon, { height: isDownMd ? 20 : 25, width: isDownMd ? 20 : 24, className: "matchid-modal-header-back", onClick: onBack }),
|
|
1279
|
+
/* @__PURE__ */ (0, import_jsx_runtime51.jsx)("span", { className: "matchid-modal-header-title", children: title })
|
|
1264
1280
|
] }),
|
|
1265
|
-
onClose && /* @__PURE__ */ (0,
|
|
1281
|
+
onClose && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(CloseRoundIcon, { size: isDownMd ? 24 : 30, className: "matchid-modal-header-close", onClick: onClose })
|
|
1266
1282
|
] }),
|
|
1267
1283
|
children
|
|
1268
1284
|
] });
|
|
@@ -1273,7 +1289,7 @@ var import_react4 = require("react");
|
|
|
1273
1289
|
|
|
1274
1290
|
// src/utils/index.tsx
|
|
1275
1291
|
var import_moment = __toESM(require("moment"));
|
|
1276
|
-
var
|
|
1292
|
+
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
1277
1293
|
var getVersion = () => {
|
|
1278
1294
|
return "0.0.2";
|
|
1279
1295
|
};
|
|
@@ -1319,10 +1335,10 @@ var NumberFormatter = ({
|
|
|
1319
1335
|
const [intPart, decimalPart] = numberValue.toString().split(".");
|
|
1320
1336
|
const intFormat = separator ? intPart.replace(/\B(?=(\d{3})+(?!\d))/g, ",") : intPart;
|
|
1321
1337
|
if (Math.abs(parseFloat(numberValue)) >= 1) {
|
|
1322
|
-
return /* @__PURE__ */ (0,
|
|
1323
|
-
prefix && /* @__PURE__ */ (0,
|
|
1324
|
-
/* @__PURE__ */ (0,
|
|
1325
|
-
decimalPart ? /* @__PURE__ */ (0,
|
|
1338
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className, children: [
|
|
1339
|
+
prefix && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: prefixClassName, children: prefix }),
|
|
1340
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: intClassName, children: intFormat }),
|
|
1341
|
+
decimalPart ? /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className: decimalClassName, children: [
|
|
1326
1342
|
".",
|
|
1327
1343
|
decimalPart.substring(0, fixNum)
|
|
1328
1344
|
] }) : "",
|
|
@@ -1339,30 +1355,30 @@ var NumberFormatter = ({
|
|
|
1339
1355
|
}
|
|
1340
1356
|
}
|
|
1341
1357
|
if (zeroCount < tFixNum) {
|
|
1342
|
-
return /* @__PURE__ */ (0,
|
|
1343
|
-
prefix && /* @__PURE__ */ (0,
|
|
1344
|
-
/* @__PURE__ */ (0,
|
|
1345
|
-
/* @__PURE__ */ (0,
|
|
1358
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className, children: [
|
|
1359
|
+
prefix && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: prefixClassName, children: prefix }),
|
|
1360
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: intClassName, children: intFormat }),
|
|
1361
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className: decimalClassName, children: [
|
|
1346
1362
|
".",
|
|
1347
1363
|
decimalPart.substring(0, tFixNum)
|
|
1348
1364
|
] }),
|
|
1349
1365
|
suffix
|
|
1350
1366
|
] });
|
|
1351
1367
|
}
|
|
1352
|
-
return /* @__PURE__ */ (0,
|
|
1353
|
-
prefix && /* @__PURE__ */ (0,
|
|
1354
|
-
/* @__PURE__ */ (0,
|
|
1355
|
-
/* @__PURE__ */ (0,
|
|
1368
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className, children: [
|
|
1369
|
+
prefix && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: prefixClassName, children: prefix }),
|
|
1370
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: intClassName, children: intFormat }),
|
|
1371
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className: decimalClassName, children: [
|
|
1356
1372
|
".0",
|
|
1357
|
-
/* @__PURE__ */ (0,
|
|
1373
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("sub", { children: zeroCount }),
|
|
1358
1374
|
decimalPart?.substring(zeroCount, zeroCount + tFixNum - 2)
|
|
1359
1375
|
] }),
|
|
1360
1376
|
suffix
|
|
1361
1377
|
] });
|
|
1362
1378
|
}
|
|
1363
|
-
return /* @__PURE__ */ (0,
|
|
1364
|
-
prefix && /* @__PURE__ */ (0,
|
|
1365
|
-
/* @__PURE__ */ (0,
|
|
1379
|
+
return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className, children: [
|
|
1380
|
+
prefix && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: prefixClassName, children: prefix }),
|
|
1381
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: intClassName, children: intPart }),
|
|
1366
1382
|
suffix
|
|
1367
1383
|
] });
|
|
1368
1384
|
};
|
|
@@ -1378,9 +1394,13 @@ var formatDate = (value, formatString = "YYYY-MM-DD HH:mm:ss") => {
|
|
|
1378
1394
|
var isInTgApp = () => {
|
|
1379
1395
|
return !!window.TelegramWebviewProxy;
|
|
1380
1396
|
};
|
|
1397
|
+
function bytesToBase64(bytes) {
|
|
1398
|
+
const binString = String.fromCodePoint(...bytes);
|
|
1399
|
+
return btoa(binString);
|
|
1400
|
+
}
|
|
1381
1401
|
|
|
1382
1402
|
// src/ui/Button/index.tsx
|
|
1383
|
-
var
|
|
1403
|
+
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
1384
1404
|
function Button({
|
|
1385
1405
|
size = "df",
|
|
1386
1406
|
disabled = false,
|
|
@@ -1399,7 +1419,7 @@ function Button({
|
|
|
1399
1419
|
onClick && onClick();
|
|
1400
1420
|
}
|
|
1401
1421
|
};
|
|
1402
|
-
return /* @__PURE__ */ (0,
|
|
1422
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
1403
1423
|
"button",
|
|
1404
1424
|
{
|
|
1405
1425
|
type,
|
|
@@ -1409,14 +1429,14 @@ function Button({
|
|
|
1409
1429
|
...style
|
|
1410
1430
|
},
|
|
1411
1431
|
onClick: onAction,
|
|
1412
|
-
children: loading ? /* @__PURE__ */ (0,
|
|
1432
|
+
children: loading ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(LoadingIcon_default, { className: "matchid-btn-loading-icon", color: "var(--matchid-btn-loading-color)" }) : children
|
|
1413
1433
|
}
|
|
1414
1434
|
);
|
|
1415
1435
|
}
|
|
1416
1436
|
|
|
1417
1437
|
// src/ui/Input/index.tsx
|
|
1418
1438
|
var import_react3 = require("react");
|
|
1419
|
-
var
|
|
1439
|
+
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
1420
1440
|
function Input({
|
|
1421
1441
|
onChange,
|
|
1422
1442
|
type,
|
|
@@ -1426,17 +1446,17 @@ function Input({
|
|
|
1426
1446
|
}) {
|
|
1427
1447
|
const [inputType, setInputType] = (0, import_react3.useState)(type);
|
|
1428
1448
|
const isDownMd = useDownMd();
|
|
1429
|
-
return /* @__PURE__ */ (0,
|
|
1449
|
+
return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
|
|
1430
1450
|
"div",
|
|
1431
1451
|
{
|
|
1432
1452
|
className: `matchid-input-box ${props.value && props.value.length > 0 ? "matchid-input-has-content" : ""} ${className}`,
|
|
1433
1453
|
children: [
|
|
1434
|
-
/* @__PURE__ */ (0,
|
|
1435
|
-
props.value && props.value.length > 0 && /* @__PURE__ */ (0,
|
|
1454
|
+
/* @__PURE__ */ (0, import_jsx_runtime54.jsx)("input", { type: inputType, onChange, ...props, className: "matchid-input-field" }),
|
|
1455
|
+
props.value && props.value.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "matchid-input-delete-icon", onClick: (e) => {
|
|
1436
1456
|
if (onChange) {
|
|
1437
1457
|
onChange({ target: { value: "" } });
|
|
1438
1458
|
}
|
|
1439
|
-
}, children: /* @__PURE__ */ (0,
|
|
1459
|
+
}, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
|
|
1440
1460
|
DeleteRoundIcon,
|
|
1441
1461
|
{
|
|
1442
1462
|
height: isDownMd ? 16 : 21,
|
|
@@ -1444,9 +1464,9 @@ function Input({
|
|
|
1444
1464
|
color: "var(--matchid-input-delete-icon-color)"
|
|
1445
1465
|
}
|
|
1446
1466
|
) }),
|
|
1447
|
-
type === "password" && /* @__PURE__ */ (0,
|
|
1467
|
+
type === "password" && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "matchid-input-eye-icon", onClick: () => {
|
|
1448
1468
|
setInputType(inputType === "password" ? "text" : "password");
|
|
1449
|
-
}, children: inputType === "password" ? /* @__PURE__ */ (0,
|
|
1469
|
+
}, children: inputType === "password" ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(CloseEyeIcon, { size: isDownMd ? 16 : 20 }) : /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(OpenEyeIcon, { size: isDownMd ? 16 : 20 }) }),
|
|
1450
1470
|
after
|
|
1451
1471
|
]
|
|
1452
1472
|
}
|
|
@@ -1454,7 +1474,7 @@ function Input({
|
|
|
1454
1474
|
}
|
|
1455
1475
|
|
|
1456
1476
|
// src/ui/Field/index.tsx
|
|
1457
|
-
var
|
|
1477
|
+
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
1458
1478
|
function Field({
|
|
1459
1479
|
label,
|
|
1460
1480
|
children,
|
|
@@ -1462,19 +1482,19 @@ function Field({
|
|
|
1462
1482
|
required,
|
|
1463
1483
|
className = ""
|
|
1464
1484
|
}) {
|
|
1465
|
-
return /* @__PURE__ */ (0,
|
|
1466
|
-
/* @__PURE__ */ (0,
|
|
1467
|
-
required && /* @__PURE__ */ (0,
|
|
1485
|
+
return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: `matchid-field-box ${className}`, children: [
|
|
1486
|
+
/* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: "matchid-field-label", children: [
|
|
1487
|
+
required && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "matchid-field-required", children: "*" }),
|
|
1468
1488
|
label
|
|
1469
1489
|
] }),
|
|
1470
1490
|
children,
|
|
1471
|
-
error && /* @__PURE__ */ (0,
|
|
1491
|
+
error && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "matchid-field-error", children: error })
|
|
1472
1492
|
] });
|
|
1473
1493
|
}
|
|
1474
1494
|
|
|
1475
1495
|
// src/components/EmailModal/StepEmail.tsx
|
|
1476
1496
|
var import_react_intl = require("react-intl");
|
|
1477
|
-
var
|
|
1497
|
+
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
1478
1498
|
function StepEmail(props) {
|
|
1479
1499
|
const intl = (0, import_react_intl.useIntl)();
|
|
1480
1500
|
const [emailVal, setEmailVal] = (0, import_react4.useState)("");
|
|
@@ -1489,10 +1509,10 @@ function StepEmail(props) {
|
|
|
1489
1509
|
const onContinue = async () => {
|
|
1490
1510
|
props.onContinue(emailVal);
|
|
1491
1511
|
};
|
|
1492
|
-
return /* @__PURE__ */ (0,
|
|
1493
|
-
/* @__PURE__ */ (0,
|
|
1512
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className: "matchid-email-email-box", children: [
|
|
1513
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Field, { label: intl.formatMessage({
|
|
1494
1514
|
id: "emailAddress"
|
|
1495
|
-
}), children: /* @__PURE__ */ (0,
|
|
1515
|
+
}), children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
|
|
1496
1516
|
Input,
|
|
1497
1517
|
{
|
|
1498
1518
|
placeholder: intl.formatMessage({
|
|
@@ -1502,9 +1522,9 @@ function StepEmail(props) {
|
|
|
1502
1522
|
value: emailVal
|
|
1503
1523
|
}
|
|
1504
1524
|
) }),
|
|
1505
|
-
/* @__PURE__ */ (0,
|
|
1525
|
+
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Button, { disabled: !canContinue, style: {
|
|
1506
1526
|
marginTop: "64px"
|
|
1507
|
-
}, onClick: onContinue, size: "lg", block: true, highlight: true, children: /* @__PURE__ */ (0,
|
|
1527
|
+
}, onClick: onContinue, size: "lg", block: true, highlight: true, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react_intl.FormattedMessage, { id: "continue" }) })
|
|
1508
1528
|
] });
|
|
1509
1529
|
}
|
|
1510
1530
|
|
|
@@ -1920,7 +1940,7 @@ var import_react9 = require("react");
|
|
|
1920
1940
|
var import_react_dom = require("react-dom");
|
|
1921
1941
|
|
|
1922
1942
|
// src/ui/Drawer/index.tsx
|
|
1923
|
-
var
|
|
1943
|
+
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
1924
1944
|
function Drawer({
|
|
1925
1945
|
children,
|
|
1926
1946
|
showClose = true,
|
|
@@ -1931,15 +1951,15 @@ function Drawer({
|
|
|
1931
1951
|
onBack
|
|
1932
1952
|
}) {
|
|
1933
1953
|
if (!isOpen) {
|
|
1934
|
-
return /* @__PURE__ */ (0,
|
|
1954
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_jsx_runtime57.Fragment, {});
|
|
1935
1955
|
}
|
|
1936
|
-
return /* @__PURE__ */ (0,
|
|
1937
|
-
/* @__PURE__ */ (0,
|
|
1938
|
-
/* @__PURE__ */ (0,
|
|
1939
|
-
onBack && /* @__PURE__ */ (0,
|
|
1956
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Overlay, { isOpen, zIndex, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "matchid-drawer", children: [
|
|
1957
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: `matchid-drawer-header matchid-flex`, children: [
|
|
1958
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: `matchid-drawer-header-content matchid-flex`, children: [
|
|
1959
|
+
onBack && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(ArrowLeftIcon, { height: 25, width: 24, className: "matchid-drawer-header-back", onClick: onBack }),
|
|
1940
1960
|
title
|
|
1941
1961
|
] }),
|
|
1942
|
-
showClose && /* @__PURE__ */ (0,
|
|
1962
|
+
showClose && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(CloseRoundIcon, { className: "matchid-drawer-header-close", onClick: onClose })
|
|
1943
1963
|
] }),
|
|
1944
1964
|
children
|
|
1945
1965
|
] }) });
|
|
@@ -1949,7 +1969,7 @@ function Drawer({
|
|
|
1949
1969
|
var import_react6 = require("react");
|
|
1950
1970
|
|
|
1951
1971
|
// src/ui/ModalDrawer/index.tsx
|
|
1952
|
-
var
|
|
1972
|
+
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
1953
1973
|
function ModalDrawer({
|
|
1954
1974
|
title,
|
|
1955
1975
|
drawerTitleVisible = true,
|
|
@@ -1957,9 +1977,9 @@ function ModalDrawer({
|
|
|
1957
1977
|
}) {
|
|
1958
1978
|
const isDownMd = useDownMd();
|
|
1959
1979
|
if (isDownMd) {
|
|
1960
|
-
return /* @__PURE__ */ (0,
|
|
1980
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(ModalWithHeader, { ...props, title });
|
|
1961
1981
|
}
|
|
1962
|
-
return /* @__PURE__ */ (0,
|
|
1982
|
+
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Drawer, { ...props, title: drawerTitleVisible ? title : null });
|
|
1963
1983
|
}
|
|
1964
1984
|
|
|
1965
1985
|
// src/assets/img/confirm.gif
|
|
@@ -2015,7 +2035,7 @@ function useHash({
|
|
|
2015
2035
|
}
|
|
2016
2036
|
|
|
2017
2037
|
// src/ui/HashPanel/index.tsx
|
|
2018
|
-
var
|
|
2038
|
+
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
2019
2039
|
function HashPanel({
|
|
2020
2040
|
hash,
|
|
2021
2041
|
chain,
|
|
@@ -2074,14 +2094,14 @@ function HashPanel({
|
|
|
2074
2094
|
}
|
|
2075
2095
|
}, [hashQuery.data]);
|
|
2076
2096
|
const link = chain ? `${chain?.blockExplorers?.default.url}/tx/${hash}` : "";
|
|
2077
|
-
return /* @__PURE__ */ (0,
|
|
2097
|
+
return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
2078
2098
|
ModalDrawer,
|
|
2079
2099
|
{
|
|
2080
2100
|
isOpen,
|
|
2081
2101
|
showClose: true,
|
|
2082
2102
|
onClose,
|
|
2083
2103
|
zIndex,
|
|
2084
|
-
title: /* @__PURE__ */ (0,
|
|
2104
|
+
title: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
|
|
2085
2105
|
"div",
|
|
2086
2106
|
{
|
|
2087
2107
|
className: "matchid-hashpanel-header",
|
|
@@ -2091,29 +2111,29 @@ function HashPanel({
|
|
|
2091
2111
|
children: statusValue.text
|
|
2092
2112
|
}
|
|
2093
2113
|
),
|
|
2094
|
-
children: /* @__PURE__ */ (0,
|
|
2095
|
-
/* @__PURE__ */ (0,
|
|
2096
|
-
/* @__PURE__ */ (0,
|
|
2114
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "matchid-hashpanel-box", children: [
|
|
2115
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "matchid-hashpanel-content", children: [
|
|
2116
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: `matchid-hashpanel-status`, style: {
|
|
2097
2117
|
color: statusValue.color
|
|
2098
2118
|
}, children: statusValue.text }),
|
|
2099
|
-
/* @__PURE__ */ (0,
|
|
2100
|
-
hash && /* @__PURE__ */ (0,
|
|
2119
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("img", { src: statusValue.icon, alt: statusValue.text, className: `matchid-hashpanel-img` }),
|
|
2120
|
+
hash && /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "matchid-hashpanel-hash", children: [
|
|
2101
2121
|
"Hash:",
|
|
2102
|
-
/* @__PURE__ */ (0,
|
|
2122
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)("a", { href: link, target: "_blank", children: hash })
|
|
2103
2123
|
] })
|
|
2104
2124
|
] }),
|
|
2105
|
-
/* @__PURE__ */ (0,
|
|
2125
|
+
/* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Button, { onClick: onClose, size: "lg", block: true, children: "Back" })
|
|
2106
2126
|
] })
|
|
2107
2127
|
}
|
|
2108
2128
|
);
|
|
2109
2129
|
}
|
|
2110
2130
|
function HashPanel_default(props) {
|
|
2111
|
-
return props.isOpen && /* @__PURE__ */ (0,
|
|
2131
|
+
return props.isOpen && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(HashPanel, { ...props });
|
|
2112
2132
|
}
|
|
2113
2133
|
|
|
2114
2134
|
// src/ui/Popover/index.tsx
|
|
2115
2135
|
var import_react7 = require("react");
|
|
2116
|
-
var
|
|
2136
|
+
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
2117
2137
|
function Popover({
|
|
2118
2138
|
children,
|
|
2119
2139
|
content,
|
|
@@ -2123,7 +2143,7 @@ function Popover({
|
|
|
2123
2143
|
gap = "20px"
|
|
2124
2144
|
}) {
|
|
2125
2145
|
const [active, setActive] = (0, import_react7.useState)(false);
|
|
2126
|
-
return children && /* @__PURE__ */ (0,
|
|
2146
|
+
return children && /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
|
|
2127
2147
|
"div",
|
|
2128
2148
|
{
|
|
2129
2149
|
onClick: () => {
|
|
@@ -2134,20 +2154,20 @@ function Popover({
|
|
|
2134
2154
|
className: `matchid-popover-box matchid-popover-${position} matchid-popover-${type} ${className} ${type == "click" && active ? "matchid-popover-click-active" : ""}`,
|
|
2135
2155
|
children: [
|
|
2136
2156
|
children,
|
|
2137
|
-
/* @__PURE__ */ (0,
|
|
2157
|
+
/* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { style: {
|
|
2138
2158
|
paddingTop: gap
|
|
2139
|
-
}, className: `matchid-popover-area`, children: /* @__PURE__ */ (0,
|
|
2159
|
+
}, className: `matchid-popover-area`, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: `matchid-popover-content`, children: content }) })
|
|
2140
2160
|
]
|
|
2141
2161
|
}
|
|
2142
2162
|
);
|
|
2143
2163
|
}
|
|
2144
2164
|
|
|
2145
2165
|
// src/ui/Switch/index.tsx
|
|
2146
|
-
var
|
|
2166
|
+
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
2147
2167
|
|
|
2148
2168
|
// src/ui/AlphaAvatar/index.tsx
|
|
2149
2169
|
var import_react8 = require("react");
|
|
2150
|
-
var
|
|
2170
|
+
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
2151
2171
|
function AlphaAvatar({
|
|
2152
2172
|
name,
|
|
2153
2173
|
size = "default",
|
|
@@ -2164,7 +2184,7 @@ function AlphaAvatar({
|
|
|
2164
2184
|
return "";
|
|
2165
2185
|
}, [name]);
|
|
2166
2186
|
const numberSize = typeof size === "number" ? size : size === "sm" ? 24 : size === "default" ? 40 : 64;
|
|
2167
|
-
return /* @__PURE__ */ (0,
|
|
2187
|
+
return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: `matchid-alpha-avatar ${className}`, style: {
|
|
2168
2188
|
width: numberSize,
|
|
2169
2189
|
height: numberSize,
|
|
2170
2190
|
fontSize: Math.ceil(numberSize / 2),
|
|
@@ -2173,7 +2193,7 @@ function AlphaAvatar({
|
|
|
2173
2193
|
}
|
|
2174
2194
|
|
|
2175
2195
|
// src/ui/Radio/index.tsx
|
|
2176
|
-
var
|
|
2196
|
+
var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
2177
2197
|
function Radio({
|
|
2178
2198
|
checked = false,
|
|
2179
2199
|
onChange,
|
|
@@ -2182,20 +2202,20 @@ function Radio({
|
|
|
2182
2202
|
className = "",
|
|
2183
2203
|
style = {}
|
|
2184
2204
|
}) {
|
|
2185
|
-
return /* @__PURE__ */ (0,
|
|
2205
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { onClick: onChange, className: `matchid-radio ${className} ${checked ? "matchid-radio-checked" : ""}`, style: {
|
|
2186
2206
|
width: size,
|
|
2187
2207
|
height: size,
|
|
2188
2208
|
...style,
|
|
2189
2209
|
// @ts-ignore
|
|
2190
2210
|
"--matchid-radio-checked": color
|
|
2191
|
-
}, children: checked && /* @__PURE__ */ (0,
|
|
2211
|
+
}, children: checked && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: `matchid-radio-content`, style: {
|
|
2192
2212
|
width: Math.floor(size * 0.7),
|
|
2193
2213
|
height: Math.floor(size * 0.7)
|
|
2194
2214
|
} }) });
|
|
2195
2215
|
}
|
|
2196
2216
|
|
|
2197
2217
|
// src/context/ModalContext.tsx
|
|
2198
|
-
var
|
|
2218
|
+
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
2199
2219
|
var ModalContext = (0, import_react9.createContext)(null);
|
|
2200
2220
|
function useModal() {
|
|
2201
2221
|
const context = (0, import_react9.useContext)(ModalContext);
|
|
@@ -2236,7 +2256,7 @@ var useTransactionStore = (0, import_zustand3.create)((0, import_middleware2.dev
|
|
|
2236
2256
|
var useTransactionStore_default = useTransactionStore;
|
|
2237
2257
|
|
|
2238
2258
|
// src/hooks/useWallet.tsx
|
|
2239
|
-
var
|
|
2259
|
+
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
2240
2260
|
var AppClientId = "react-sdk-" + getVersion();
|
|
2241
2261
|
function useWallet() {
|
|
2242
2262
|
const { address, wallet: walletConfig } = useLocalStore_default();
|
|
@@ -2409,7 +2429,7 @@ function useWallet() {
|
|
|
2409
2429
|
address: evmAccount.address
|
|
2410
2430
|
});
|
|
2411
2431
|
modal.show((props) => {
|
|
2412
|
-
return /* @__PURE__ */ (0,
|
|
2432
|
+
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(HashPanel_default, { isOpen: true, onClose: props.close, zIndex: props.zIndex, hash: txHash, chain: _chain });
|
|
2413
2433
|
});
|
|
2414
2434
|
clearInterval(window.matchProvider.transactionMessageIntervalMap[transactionId].interval);
|
|
2415
2435
|
delete window.matchProvider.transactionMessageIntervalMap[transactionId];
|
|
@@ -2486,7 +2506,7 @@ function useCopyClipboard(timeout = 500) {
|
|
|
2486
2506
|
// src/context/ToastContext.tsx
|
|
2487
2507
|
var import_react12 = require("react");
|
|
2488
2508
|
var import_react_dom2 = require("react-dom");
|
|
2489
|
-
var
|
|
2509
|
+
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
2490
2510
|
var ToastContext = (0, import_react12.createContext)(null);
|
|
2491
2511
|
|
|
2492
2512
|
// src/hooks/api/wallet.ts
|
|
@@ -2548,7 +2568,7 @@ function useImportTokenListQuery({
|
|
|
2548
2568
|
var import_react13 = require("react");
|
|
2549
2569
|
var import_viem5 = require("viem");
|
|
2550
2570
|
var import_react_intl2 = require("react-intl");
|
|
2551
|
-
var
|
|
2571
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
2552
2572
|
function useMatchChain() {
|
|
2553
2573
|
const chainListQuery = useChainListQuery();
|
|
2554
2574
|
const modal = useModal();
|
|
@@ -2579,28 +2599,28 @@ function useMatchChain() {
|
|
|
2579
2599
|
const { chainId: storeChainId2, setChainId: setChainId2 } = useLocalStore_default();
|
|
2580
2600
|
const [selectedChainId, setSelectedChainId] = (0, import_react13.useState)(storeChainId2);
|
|
2581
2601
|
const isDownMd = useDownMd();
|
|
2582
|
-
return /* @__PURE__ */ (0,
|
|
2583
|
-
/* @__PURE__ */ (0,
|
|
2584
|
-
return /* @__PURE__ */ (0,
|
|
2602
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: `matchid-change-network-box`, children: [
|
|
2603
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("div", { className: `matchid-change-network-list`, children: chainListQuery.data?.map((item, index) => {
|
|
2604
|
+
return /* @__PURE__ */ (0, import_jsx_runtime67.jsxs)(
|
|
2585
2605
|
"div",
|
|
2586
2606
|
{
|
|
2587
2607
|
onClick: () => setSelectedChainId(item.id),
|
|
2588
2608
|
className: `matchid-change-network-item ${selectedChainId == item.id ? "matchid-change-network-selected" : ""}`,
|
|
2589
2609
|
children: [
|
|
2590
|
-
/* @__PURE__ */ (0,
|
|
2591
|
-
/* @__PURE__ */ (0,
|
|
2592
|
-
/* @__PURE__ */ (0,
|
|
2610
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsxs)("div", { className: `matchid-change-network-item-content`, children: [
|
|
2611
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("img", { src: item.iconUrl, className: `matchid-change-network-item-icon` }),
|
|
2612
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)("span", { className: "matchid-change-network-item-name", children: item.name })
|
|
2593
2613
|
] }),
|
|
2594
|
-
/* @__PURE__ */ (0,
|
|
2614
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(Radio, { checked: selectedChainId === item.id, size: isDownMd ? 18 : 24 })
|
|
2595
2615
|
]
|
|
2596
2616
|
},
|
|
2597
2617
|
index
|
|
2598
2618
|
);
|
|
2599
2619
|
}) }),
|
|
2600
|
-
/* @__PURE__ */ (0,
|
|
2620
|
+
/* @__PURE__ */ (0, import_jsx_runtime67.jsx)(Button, { size: "lg", highlight: true, onClick: () => {
|
|
2601
2621
|
setChainId2(selectedChainId || 0);
|
|
2602
2622
|
close();
|
|
2603
|
-
}, block: true, children: /* @__PURE__ */ (0,
|
|
2623
|
+
}, block: true, children: /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(import_react_intl2.FormattedMessage, { id: "confirm" }) })
|
|
2604
2624
|
] });
|
|
2605
2625
|
}
|
|
2606
2626
|
const showChangeNetwork = () => {
|
|
@@ -2718,10 +2738,10 @@ var import_viem6 = require("viem");
|
|
|
2718
2738
|
var import_react_query3 = require("@tanstack/react-query");
|
|
2719
2739
|
|
|
2720
2740
|
// src/components/ImportToken/index.tsx
|
|
2721
|
-
var
|
|
2741
|
+
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
2722
2742
|
|
|
2723
2743
|
// src/hooks/useMatchWallet.tsx
|
|
2724
|
-
var
|
|
2744
|
+
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
2725
2745
|
function useMatchWalletRecords() {
|
|
2726
2746
|
const [hasMore, setHasMore] = (0, import_react15.useState)(true);
|
|
2727
2747
|
const [items, setItems] = (0, import_react15.useState)([]);
|
|
@@ -3030,39 +3050,39 @@ var CACHE_TTL2 = 86400 * 30 * 1e3;
|
|
|
3030
3050
|
var import_zustand5 = require("zustand");
|
|
3031
3051
|
|
|
3032
3052
|
// src/hooks/useConfig.tsx
|
|
3033
|
-
var
|
|
3053
|
+
var import_jsx_runtime70 = require("react/jsx-runtime");
|
|
3034
3054
|
var DEFAULT_WALLET_METHODS = ["evm", "sol", "btc", "tron", "ton"];
|
|
3035
3055
|
var WALLET_METHODS = ["evm", "sol", "btc", "tron", "ton"];
|
|
3036
3056
|
function useWalletConfig() {
|
|
3037
3057
|
const isDownMd = useDownMd();
|
|
3038
3058
|
const walletMap = {
|
|
3039
3059
|
evm: {
|
|
3040
|
-
icon: /* @__PURE__ */ (0,
|
|
3041
|
-
activeIcon: /* @__PURE__ */ (0,
|
|
3060
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(EVMDarkIcon, { size: isDownMd ? 36 : 40 }),
|
|
3061
|
+
activeIcon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(EVMLightIcon, { size: isDownMd ? 36 : 40 }),
|
|
3042
3062
|
name: "EVM",
|
|
3043
3063
|
method: "evm"
|
|
3044
3064
|
},
|
|
3045
3065
|
sol: {
|
|
3046
|
-
icon: /* @__PURE__ */ (0,
|
|
3047
|
-
activeIcon: /* @__PURE__ */ (0,
|
|
3066
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(SOLDarkIcon, { size: isDownMd ? 36 : 40 }),
|
|
3067
|
+
activeIcon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(SOLLightIcon, { size: isDownMd ? 36 : 40 }),
|
|
3048
3068
|
name: "SOL",
|
|
3049
3069
|
method: "sol"
|
|
3050
3070
|
},
|
|
3051
3071
|
btc: {
|
|
3052
|
-
icon: /* @__PURE__ */ (0,
|
|
3053
|
-
activeIcon: /* @__PURE__ */ (0,
|
|
3072
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(BTCDarkIcon, { size: isDownMd ? 36 : 40 }),
|
|
3073
|
+
activeIcon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(BTCLightIcon, { size: isDownMd ? 36 : 40 }),
|
|
3054
3074
|
name: "BTC",
|
|
3055
3075
|
method: "btc"
|
|
3056
3076
|
},
|
|
3057
3077
|
tron: {
|
|
3058
|
-
icon: /* @__PURE__ */ (0,
|
|
3059
|
-
activeIcon: /* @__PURE__ */ (0,
|
|
3078
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(TRXDarkIcon, { size: isDownMd ? 36 : 40 }),
|
|
3079
|
+
activeIcon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(TRXLightIcon, { size: isDownMd ? 36 : 40 }),
|
|
3060
3080
|
name: "TRON",
|
|
3061
3081
|
method: "tron"
|
|
3062
3082
|
},
|
|
3063
3083
|
ton: {
|
|
3064
|
-
icon: /* @__PURE__ */ (0,
|
|
3065
|
-
activeIcon: /* @__PURE__ */ (0,
|
|
3084
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(TonLightIcon, { size: isDownMd ? 36 : 40 }),
|
|
3085
|
+
activeIcon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(TonLightIcon2, { size: isDownMd ? 36 : 40 }),
|
|
3066
3086
|
name: "TON",
|
|
3067
3087
|
method: "ton"
|
|
3068
3088
|
}
|
|
@@ -3073,12 +3093,6 @@ function useWalletConfig() {
|
|
|
3073
3093
|
}
|
|
3074
3094
|
|
|
3075
3095
|
// src/store/useModalStore.ts
|
|
3076
|
-
var useSOLModalStore = (0, import_zustand5.create)((set) => ({
|
|
3077
|
-
isOpen: false,
|
|
3078
|
-
type: "",
|
|
3079
|
-
open: (type) => set({ isOpen: true, type }),
|
|
3080
|
-
close: () => set({ isOpen: false })
|
|
3081
|
-
}));
|
|
3082
3096
|
var useTRONModalStore = (0, import_zustand5.create)((set) => ({
|
|
3083
3097
|
isOpen: false,
|
|
3084
3098
|
type: "",
|
|
@@ -3114,14 +3128,14 @@ var useWalletModalStore = (0, import_zustand5.create)((set) => ({
|
|
|
3114
3128
|
// src/components/CEXBindModal/index.tsx
|
|
3115
3129
|
var import_react18 = require("react");
|
|
3116
3130
|
var import_react_intl5 = require("react-intl");
|
|
3117
|
-
var
|
|
3131
|
+
var import_jsx_runtime71 = require("react/jsx-runtime");
|
|
3118
3132
|
|
|
3119
3133
|
// src/context/BusinessProvider.tsx
|
|
3120
3134
|
var import_react_query8 = require("@tanstack/react-query");
|
|
3121
|
-
var
|
|
3135
|
+
var import_jsx_runtime72 = require("react/jsx-runtime");
|
|
3122
3136
|
|
|
3123
3137
|
// src/context/index.tsx
|
|
3124
|
-
var
|
|
3138
|
+
var import_jsx_runtime73 = require("react/jsx-runtime");
|
|
3125
3139
|
|
|
3126
3140
|
// src/hooks/useWalletInit.ts
|
|
3127
3141
|
var import_react19 = require("react");
|
|
@@ -3133,7 +3147,7 @@ var import_react20 = require("react");
|
|
|
3133
3147
|
// src/MatchContext.tsx
|
|
3134
3148
|
var import_react_query9 = require("@tanstack/react-query");
|
|
3135
3149
|
var import_react_intl6 = require("react-intl");
|
|
3136
|
-
var
|
|
3150
|
+
var import_jsx_runtime74 = require("react/jsx-runtime");
|
|
3137
3151
|
var queryClient = new import_react_query9.QueryClient();
|
|
3138
3152
|
var MatchContext = (0, import_react21.createContext)(void 0);
|
|
3139
3153
|
var useMatch = () => {
|
|
@@ -3160,13 +3174,16 @@ function useUserInfo() {
|
|
|
3160
3174
|
refreshOverview
|
|
3161
3175
|
} = useLocalStore_default();
|
|
3162
3176
|
const { setTgAppAuthCode, emailLoginKey, setEmailLoginKey } = useStore_default();
|
|
3177
|
+
const isDownMd = useDownMd();
|
|
3163
3178
|
const { events, login } = useMatch();
|
|
3164
|
-
const { open: SOLOpen } = useSOLModalStore();
|
|
3165
3179
|
const { open: TRONOpen } = useTRONModalStore();
|
|
3166
3180
|
const { open: TONOpen } = useTONModalStore();
|
|
3167
3181
|
const { open: BTCOpen } = useBTCModalStore();
|
|
3168
3182
|
const { open: CEXBindOpen } = useCEXBindModalStore();
|
|
3169
3183
|
const walletModalStore = useWalletModalStore();
|
|
3184
|
+
const getRedirectUri = () => {
|
|
3185
|
+
return encodeURIComponent(window.location.href);
|
|
3186
|
+
};
|
|
3170
3187
|
const isLogin = (0, import_react22.useMemo)(() => !!token && !!overview, [token, overview]);
|
|
3171
3188
|
const logout = async () => {
|
|
3172
3189
|
try {
|
|
@@ -3237,6 +3254,9 @@ function useUserInfo() {
|
|
|
3237
3254
|
case "evm":
|
|
3238
3255
|
return window.open(`${endpoints.auth}login/wallet?appid=${appid}&locale=${locale}`);
|
|
3239
3256
|
case "sol":
|
|
3257
|
+
if (isDownMd) {
|
|
3258
|
+
return window.location.href = `${endpoints.auth}login/sol?appid=${appid}&locale=${locale}&redirect_uri=${getRedirectUri()}`;
|
|
3259
|
+
}
|
|
3240
3260
|
return window.open(`${endpoints.auth}login/sol?appid=${appid}&locale=${locale}`);
|
|
3241
3261
|
case "tron":
|
|
3242
3262
|
return TRONOpen("login");
|
|
@@ -3279,7 +3299,7 @@ function useUserInfo() {
|
|
|
3279
3299
|
const res = await verifyEmailCodeApi(obj);
|
|
3280
3300
|
if (res && res.data && isSuccess(res)) {
|
|
3281
3301
|
await login({
|
|
3282
|
-
mid: res.data.mid,
|
|
3302
|
+
// mid: res.data.mid,
|
|
3283
3303
|
token: `${res.data.token_type} ${res.data.access_token}`
|
|
3284
3304
|
});
|
|
3285
3305
|
return true;
|
|
@@ -3326,7 +3346,10 @@ function useUserInfo() {
|
|
|
3326
3346
|
case "evm":
|
|
3327
3347
|
return window.open(`${endpoints.auth}bind/wallet?appid=${appid}&locale=${locale}&st=` + encodeURIComponent(encodeBase64(token)));
|
|
3328
3348
|
case "sol":
|
|
3329
|
-
|
|
3349
|
+
if (isDownMd) {
|
|
3350
|
+
return window.location.href = `${endpoints.auth}bind/sol?appid=${appid}&locale=${locale}&st=${encodeURIComponent(encodeBase64(token))}&redirect_uri=${getRedirectUri()}`;
|
|
3351
|
+
}
|
|
3352
|
+
return window.open(`${endpoints.auth}bind/sol?appid=${appid}&locale=${locale}&st=${encodeURIComponent(encodeBase64(token))}`);
|
|
3330
3353
|
case "tron":
|
|
3331
3354
|
return TRONOpen("bind");
|
|
3332
3355
|
case "ton":
|
|
@@ -3426,7 +3449,7 @@ function useUserInfo() {
|
|
|
3426
3449
|
// src/components/EmailModal/StepVerify.tsx
|
|
3427
3450
|
var import_react23 = require("react");
|
|
3428
3451
|
var import_react_intl7 = require("react-intl");
|
|
3429
|
-
var
|
|
3452
|
+
var import_jsx_runtime75 = require("react/jsx-runtime");
|
|
3430
3453
|
function StepVerify(props) {
|
|
3431
3454
|
const intl = (0, import_react_intl7.useIntl)();
|
|
3432
3455
|
const { getLoginEmailCode, loginByEmail } = useUserInfo();
|
|
@@ -3503,17 +3526,17 @@ function StepVerify(props) {
|
|
|
3503
3526
|
setSubmitting(false);
|
|
3504
3527
|
}
|
|
3505
3528
|
};
|
|
3506
|
-
return /* @__PURE__ */ (0,
|
|
3507
|
-
/* @__PURE__ */ (0,
|
|
3508
|
-
/* @__PURE__ */ (0,
|
|
3509
|
-
/* @__PURE__ */ (0,
|
|
3510
|
-
/* @__PURE__ */ (0,
|
|
3511
|
-
/* @__PURE__ */ (0,
|
|
3529
|
+
return /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: "matchid-email-verify-box", children: [
|
|
3530
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: "matchid-email-verify-header", children: [
|
|
3531
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: "matchid-email-verify-header-icon", children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(EmailLineIcon, { size: isDownMd ? 19 : 24 }) }),
|
|
3532
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsxs)("div", { className: "matchid-email-verify-header-content", children: [
|
|
3533
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: "matchid-email-verify-header-value", children: props.email }),
|
|
3534
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)("div", { className: "matchid-email-verify-header-tips", children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_react_intl7.FormattedMessage, { id: "sendEmailTips" }) })
|
|
3512
3535
|
] })
|
|
3513
3536
|
] }),
|
|
3514
|
-
/* @__PURE__ */ (0,
|
|
3537
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Field, { label: intl.formatMessage({
|
|
3515
3538
|
id: "verificationCode"
|
|
3516
|
-
}), error, children: /* @__PURE__ */ (0,
|
|
3539
|
+
}), error, children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
3517
3540
|
Input,
|
|
3518
3541
|
{
|
|
3519
3542
|
placeholder: intl.formatMessage({
|
|
@@ -3523,7 +3546,7 @@ function StepVerify(props) {
|
|
|
3523
3546
|
maxLength: codeLength,
|
|
3524
3547
|
onChange: (e) => setCode(e.target.value),
|
|
3525
3548
|
value: code,
|
|
3526
|
-
after: /* @__PURE__ */ (0,
|
|
3549
|
+
after: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
3527
3550
|
Button,
|
|
3528
3551
|
{
|
|
3529
3552
|
highlight: true,
|
|
@@ -3542,13 +3565,13 @@ function StepVerify(props) {
|
|
|
3542
3565
|
)
|
|
3543
3566
|
}
|
|
3544
3567
|
) }),
|
|
3545
|
-
/* @__PURE__ */ (0,
|
|
3568
|
+
/* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Button, { disabled: !canContinue, highlight: true, block: true, size: "lg", onClick: onContinue, children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_react_intl7.FormattedMessage, { id: "continue" }) })
|
|
3546
3569
|
] });
|
|
3547
3570
|
}
|
|
3548
3571
|
|
|
3549
3572
|
// src/components/EmailModal/index.tsx
|
|
3550
3573
|
var import_react_intl8 = require("react-intl");
|
|
3551
|
-
var
|
|
3574
|
+
var import_jsx_runtime76 = require("react/jsx-runtime");
|
|
3552
3575
|
function EmailModal({
|
|
3553
3576
|
isOpen = false,
|
|
3554
3577
|
width = 480,
|
|
@@ -3565,7 +3588,7 @@ function EmailModal({
|
|
|
3565
3588
|
setEmailVal("");
|
|
3566
3589
|
}
|
|
3567
3590
|
}, [isOpen]);
|
|
3568
|
-
return /* @__PURE__ */ (0,
|
|
3591
|
+
return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
|
|
3569
3592
|
ModalWithHeader,
|
|
3570
3593
|
{
|
|
3571
3594
|
isOpen,
|
|
@@ -3575,10 +3598,10 @@ function EmailModal({
|
|
|
3575
3598
|
id: "email"
|
|
3576
3599
|
}),
|
|
3577
3600
|
onBack: step == "verify" ? () => setStep("input") : onBack,
|
|
3578
|
-
children: step === "input" ? /* @__PURE__ */ (0,
|
|
3601
|
+
children: step === "input" ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(StepEmail, { email: emailVal, onContinue: (email) => {
|
|
3579
3602
|
setEmailVal(email);
|
|
3580
3603
|
setStep("verify");
|
|
3581
|
-
} }) : /* @__PURE__ */ (0,
|
|
3604
|
+
} }) : /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(StepVerify, { email: emailVal, onSuccess: onLogin })
|
|
3582
3605
|
}
|
|
3583
3606
|
);
|
|
3584
3607
|
}
|
|
@@ -3608,7 +3631,7 @@ function useAppConfig() {
|
|
|
3608
3631
|
}
|
|
3609
3632
|
|
|
3610
3633
|
// src/components/LoginBox/index.tsx
|
|
3611
|
-
var
|
|
3634
|
+
var import_jsx_runtime77 = require("react/jsx-runtime");
|
|
3612
3635
|
var RecommendItem = ({
|
|
3613
3636
|
icon,
|
|
3614
3637
|
name,
|
|
@@ -3617,20 +3640,20 @@ var RecommendItem = ({
|
|
|
3617
3640
|
children,
|
|
3618
3641
|
footer
|
|
3619
3642
|
}) => {
|
|
3620
|
-
return /* @__PURE__ */ (0,
|
|
3621
|
-
/* @__PURE__ */ (0,
|
|
3622
|
-
/* @__PURE__ */ (0,
|
|
3623
|
-
/* @__PURE__ */ (0,
|
|
3624
|
-
/* @__PURE__ */ (0,
|
|
3643
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-recommend-method", children: [
|
|
3644
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-recommend-method-item", onClick, children: [
|
|
3645
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-recommend-method-content", children: [
|
|
3646
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-recommend-method-icon", children: icon }),
|
|
3647
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("span", { className: "matchid-login-recommend-method-name", children: name })
|
|
3625
3648
|
] }),
|
|
3626
|
-
footer ? footer : children ? /* @__PURE__ */ (0,
|
|
3649
|
+
footer ? footer : children ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3627
3650
|
ArrowDownIcon,
|
|
3628
3651
|
{
|
|
3629
3652
|
className: `matchid-login-recommend-method-arrow ${showChildren ? "matchid-login-recommend-method-arrow-active" : ""}`,
|
|
3630
3653
|
size: 20,
|
|
3631
3654
|
color: "var(--matchid-arrow-color)"
|
|
3632
3655
|
}
|
|
3633
|
-
) : /* @__PURE__ */ (0,
|
|
3656
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3634
3657
|
ArrowRightIcon,
|
|
3635
3658
|
{
|
|
3636
3659
|
className: "matchid-login-recommend-method-arrow",
|
|
@@ -3639,7 +3662,7 @@ var RecommendItem = ({
|
|
|
3639
3662
|
}
|
|
3640
3663
|
)
|
|
3641
3664
|
] }),
|
|
3642
|
-
children && /* @__PURE__ */ (0,
|
|
3665
|
+
children && /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3643
3666
|
"div",
|
|
3644
3667
|
{
|
|
3645
3668
|
className: `matchid-login-recommend-method-popover ${showChildren ? "matchid-login-recommend-method-popover-active" : ""}`,
|
|
@@ -3704,75 +3727,75 @@ function LoginBox({
|
|
|
3704
3727
|
const isDownMd = useDownMd();
|
|
3705
3728
|
const methodMap = {
|
|
3706
3729
|
wallet: {
|
|
3707
|
-
icon: /* @__PURE__ */ (0,
|
|
3730
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(WalletIcon, { size: isDownMd ? 36 : 40 }),
|
|
3708
3731
|
name: intl.formatMessage({ id: "wallet" }),
|
|
3709
3732
|
onClick: () => setShowWallet(!showWallet),
|
|
3710
3733
|
type: "wallet"
|
|
3711
3734
|
},
|
|
3712
3735
|
email: {
|
|
3713
|
-
icon: /* @__PURE__ */ (0,
|
|
3736
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(EmailIcon, { size: isDownMd ? 36 : 40 }),
|
|
3714
3737
|
name: intl.formatMessage({ id: "email" }),
|
|
3715
3738
|
onClick: () => {
|
|
3716
3739
|
setEmailOpen(true);
|
|
3717
3740
|
}
|
|
3718
3741
|
},
|
|
3719
3742
|
google: {
|
|
3720
|
-
icon: /* @__PURE__ */ (0,
|
|
3743
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(GoogleIcon, { size: isDownMd ? 36 : 40 }),
|
|
3721
3744
|
name: "Google",
|
|
3722
3745
|
onClick: () => login("google")
|
|
3723
3746
|
},
|
|
3724
3747
|
twitter: {
|
|
3725
|
-
icon: /* @__PURE__ */ (0,
|
|
3748
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(XIcon, { size: isDownMd ? 36 : 40 }),
|
|
3726
3749
|
name: "X",
|
|
3727
3750
|
onClick: () => login("twitter")
|
|
3728
3751
|
},
|
|
3729
3752
|
telegram: {
|
|
3730
|
-
icon: /* @__PURE__ */ (0,
|
|
3753
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(TelegramIcon, { size: isDownMd ? 36 : 40 }),
|
|
3731
3754
|
name: "Telegram",
|
|
3732
3755
|
onClick: () => login("telegram")
|
|
3733
3756
|
},
|
|
3734
3757
|
github: {
|
|
3735
|
-
icon: /* @__PURE__ */ (0,
|
|
3758
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(GithubIcon, { size: isDownMd ? 36 : 40 }),
|
|
3736
3759
|
name: "Github",
|
|
3737
3760
|
onClick: () => login("github")
|
|
3738
3761
|
},
|
|
3739
3762
|
discord: {
|
|
3740
|
-
icon: /* @__PURE__ */ (0,
|
|
3763
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(DiscordIcon, { size: isDownMd ? 36 : 40 }),
|
|
3741
3764
|
name: "Discord",
|
|
3742
3765
|
onClick: () => login("discord")
|
|
3743
3766
|
},
|
|
3744
3767
|
linkedin: {
|
|
3745
|
-
icon: /* @__PURE__ */ (0,
|
|
3768
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(LinkedinIcon, { size: isDownMd ? 36 : 40 }),
|
|
3746
3769
|
name: "LinkedIn",
|
|
3747
3770
|
onClick: () => login("linkedin")
|
|
3748
3771
|
},
|
|
3749
3772
|
facebook: {
|
|
3750
|
-
icon: /* @__PURE__ */ (0,
|
|
3773
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(FacebookIcon, { size: isDownMd ? 36 : 40 }),
|
|
3751
3774
|
name: "Facebook",
|
|
3752
3775
|
onClick: () => login("facebook")
|
|
3753
3776
|
},
|
|
3754
3777
|
youtube: {
|
|
3755
|
-
icon: /* @__PURE__ */ (0,
|
|
3778
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(YoutubeIcon, { size: isDownMd ? 36 : 40 }),
|
|
3756
3779
|
name: "Youtube",
|
|
3757
3780
|
onClick: () => login("youtube")
|
|
3758
3781
|
}
|
|
3759
3782
|
};
|
|
3760
3783
|
const { walletMap } = useWalletConfig();
|
|
3761
|
-
return /* @__PURE__ */ (0,
|
|
3762
|
-
(!inModal || !emailOpen) && /* @__PURE__ */ (0,
|
|
3763
|
-
/* @__PURE__ */ (0,
|
|
3764
|
-
return /* @__PURE__ */ (0,
|
|
3784
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_jsx_runtime77.Fragment, { children: [
|
|
3785
|
+
(!inModal || !emailOpen) && /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-box", children: [
|
|
3786
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-recommend-list", children: methodConfig.recommendMethods.map((m) => {
|
|
3787
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3765
3788
|
RecommendItem,
|
|
3766
3789
|
{
|
|
3767
3790
|
icon: methodMap[m]?.icon,
|
|
3768
3791
|
name: methodMap[m]?.name,
|
|
3769
3792
|
onClick: methodMap[m]?.onClick,
|
|
3770
3793
|
showChildren: m == "wallet" && showWallet,
|
|
3771
|
-
children: m == "wallet" && /* @__PURE__ */ (0,
|
|
3772
|
-
/* @__PURE__ */ (0,
|
|
3773
|
-
/* @__PURE__ */ (0,
|
|
3794
|
+
children: m == "wallet" && /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_jsx_runtime77.Fragment, { children: [
|
|
3795
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-recommend-wallet-divider" }),
|
|
3796
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-recommend-wallet-list", children: methodConfig.walletMethods.map((n) => {
|
|
3774
3797
|
const m2 = walletMap[n];
|
|
3775
|
-
return /* @__PURE__ */ (0,
|
|
3798
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(
|
|
3776
3799
|
"div",
|
|
3777
3800
|
{
|
|
3778
3801
|
className: "matchid-login-recommend-wallet-item",
|
|
@@ -3780,16 +3803,16 @@ function LoginBox({
|
|
|
3780
3803
|
login(m2.method);
|
|
3781
3804
|
},
|
|
3782
3805
|
children: [
|
|
3783
|
-
/* @__PURE__ */ (0,
|
|
3784
|
-
/* @__PURE__ */ (0,
|
|
3785
|
-
/* @__PURE__ */ (0,
|
|
3806
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-recommend-wallet-item-content", children: [
|
|
3807
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-recommend-wallet-item-icon", children: m2.icon }),
|
|
3808
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3786
3809
|
"div",
|
|
3787
3810
|
{
|
|
3788
3811
|
className: "matchid-login-recommend-wallet-item-hover-icon",
|
|
3789
3812
|
children: m2.activeIcon
|
|
3790
3813
|
}
|
|
3791
3814
|
),
|
|
3792
|
-
/* @__PURE__ */ (0,
|
|
3815
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3793
3816
|
"span",
|
|
3794
3817
|
{
|
|
3795
3818
|
className: "matchid-login-recommend-wallet-item-name",
|
|
@@ -3797,7 +3820,7 @@ function LoginBox({
|
|
|
3797
3820
|
}
|
|
3798
3821
|
)
|
|
3799
3822
|
] }),
|
|
3800
|
-
/* @__PURE__ */ (0,
|
|
3823
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3801
3824
|
ArrowRightIcon,
|
|
3802
3825
|
{
|
|
3803
3826
|
className: "matchid-login-recommend-wallet-item-arrow",
|
|
@@ -3815,10 +3838,10 @@ function LoginBox({
|
|
|
3815
3838
|
m
|
|
3816
3839
|
);
|
|
3817
3840
|
}) }),
|
|
3818
|
-
methodConfig.methods.length > 0 && /* @__PURE__ */ (0,
|
|
3819
|
-
/* @__PURE__ */ (0,
|
|
3820
|
-
/* @__PURE__ */ (0,
|
|
3821
|
-
return /* @__PURE__ */ (0,
|
|
3841
|
+
methodConfig.methods.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)("div", { className: "matchid-login-other", children: [
|
|
3842
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-other-text", children: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_react_intl9.FormattedMessage, { id: "otherLoginMethods" }) }),
|
|
3843
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)("div", { className: "matchid-login-method-box", children: methodConfig.methods.map((m) => {
|
|
3844
|
+
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3822
3845
|
"div",
|
|
3823
3846
|
{
|
|
3824
3847
|
className: "matchid-login-method-item",
|
|
@@ -3831,7 +3854,7 @@ function LoginBox({
|
|
|
3831
3854
|
}) })
|
|
3832
3855
|
] })
|
|
3833
3856
|
] }),
|
|
3834
|
-
/* @__PURE__ */ (0,
|
|
3857
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(
|
|
3835
3858
|
EmailModal,
|
|
3836
3859
|
{
|
|
3837
3860
|
isOpen: emailOpen,
|
|
@@ -3851,40 +3874,40 @@ var import_react27 = require("react");
|
|
|
3851
3874
|
|
|
3852
3875
|
// src/components/LoginPanel/index.tsx
|
|
3853
3876
|
var import_react_intl10 = require("react-intl");
|
|
3854
|
-
var
|
|
3877
|
+
var import_jsx_runtime78 = require("react/jsx-runtime");
|
|
3855
3878
|
function LoginPanel({
|
|
3856
3879
|
header,
|
|
3857
3880
|
onClose,
|
|
3858
3881
|
...props
|
|
3859
3882
|
}) {
|
|
3860
3883
|
const isDownMd = useDownMd();
|
|
3861
|
-
return /* @__PURE__ */ (0,
|
|
3862
|
-
header ? header : /* @__PURE__ */ (0,
|
|
3863
|
-
/* @__PURE__ */ (0,
|
|
3864
|
-
/* @__PURE__ */ (0,
|
|
3865
|
-
/* @__PURE__ */ (0,
|
|
3884
|
+
return /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("div", { className: "matchid-login-panel", children: [
|
|
3885
|
+
header ? header : /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("div", { className: "matchid-login-panel-header", children: [
|
|
3886
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsxs)("div", { className: "matchid-login-panel-header-content", children: [
|
|
3887
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "matchid-login-panel-header-title", children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_react_intl10.FormattedMessage, { id: "loginTitle" }) }),
|
|
3888
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "matchid-login-panel-header-subtilte", children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_react_intl10.FormattedMessage, { id: "loginTips" }) })
|
|
3866
3889
|
] }),
|
|
3867
|
-
onClose && /* @__PURE__ */ (0,
|
|
3890
|
+
onClose && /* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "matchid-login-panel-header-close", onClick: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(CloseRoundIcon, { size: isDownMd ? 24 : 30 }) })
|
|
3868
3891
|
] }),
|
|
3869
|
-
/* @__PURE__ */ (0,
|
|
3870
|
-
/* @__PURE__ */ (0,
|
|
3892
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "matchid-login-panel-divide" }),
|
|
3893
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)("div", { className: "matchid-login-panel-box", children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(LoginBox, { ...props }) })
|
|
3871
3894
|
] });
|
|
3872
3895
|
}
|
|
3873
3896
|
|
|
3874
3897
|
// src/components/LoginModal/index.tsx
|
|
3875
|
-
var
|
|
3898
|
+
var import_jsx_runtime79 = require("react/jsx-runtime");
|
|
3876
3899
|
function LoginModal({
|
|
3877
3900
|
isOpen = false,
|
|
3878
3901
|
width = 480,
|
|
3879
3902
|
...props
|
|
3880
3903
|
}) {
|
|
3881
3904
|
const { isLogin } = useUserInfo();
|
|
3882
|
-
return /* @__PURE__ */ (0,
|
|
3905
|
+
return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
|
|
3883
3906
|
Modal,
|
|
3884
3907
|
{
|
|
3885
3908
|
isOpen: isOpen && !isLogin,
|
|
3886
3909
|
width,
|
|
3887
|
-
children: /* @__PURE__ */ (0,
|
|
3910
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(LoginPanel, { ...props, inModal: true })
|
|
3888
3911
|
}
|
|
3889
3912
|
);
|
|
3890
3913
|
}
|
|
@@ -3893,10 +3916,10 @@ function LoginModal({
|
|
|
3893
3916
|
var import_react26 = require("react");
|
|
3894
3917
|
|
|
3895
3918
|
// src/assets/icon/ProfileIcon.tsx
|
|
3896
|
-
var
|
|
3919
|
+
var import_jsx_runtime80 = require("react/jsx-runtime");
|
|
3897
3920
|
function ProfileIcon({ size = 24, color = "black", ...props }) {
|
|
3898
|
-
return /* @__PURE__ */ (0,
|
|
3899
|
-
/* @__PURE__ */ (0,
|
|
3921
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("svg", { width: size, height: size, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
|
|
3922
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
3900
3923
|
"path",
|
|
3901
3924
|
{
|
|
3902
3925
|
fillRule: "evenodd",
|
|
@@ -3905,7 +3928,7 @@ function ProfileIcon({ size = 24, color = "black", ...props }) {
|
|
|
3905
3928
|
fill: color
|
|
3906
3929
|
}
|
|
3907
3930
|
),
|
|
3908
|
-
/* @__PURE__ */ (0,
|
|
3931
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
3909
3932
|
"path",
|
|
3910
3933
|
{
|
|
3911
3934
|
fillRule: "evenodd",
|
|
@@ -3919,7 +3942,7 @@ function ProfileIcon({ size = 24, color = "black", ...props }) {
|
|
|
3919
3942
|
|
|
3920
3943
|
// src/components/UserPopover/index.tsx
|
|
3921
3944
|
var import_react_intl11 = require("react-intl");
|
|
3922
|
-
var
|
|
3945
|
+
var import_jsx_runtime81 = require("react/jsx-runtime");
|
|
3923
3946
|
function UserContent() {
|
|
3924
3947
|
const { logout, address, username } = useUserInfo();
|
|
3925
3948
|
const [logouting, setLogouting] = (0, import_react26.useState)(false);
|
|
@@ -3940,34 +3963,34 @@ function UserContent() {
|
|
|
3940
3963
|
rightIcon,
|
|
3941
3964
|
onClick
|
|
3942
3965
|
}) => {
|
|
3943
|
-
return /* @__PURE__ */ (0,
|
|
3944
|
-
/* @__PURE__ */ (0,
|
|
3966
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "matchid-user-popover-item", onClick, children: [
|
|
3967
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: `matchid-user-popover-item-content`, children: [
|
|
3945
3968
|
icon,
|
|
3946
|
-
/* @__PURE__ */ (0,
|
|
3969
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: "matchid-user-popover-item-text", children })
|
|
3947
3970
|
] }),
|
|
3948
3971
|
rightIcon
|
|
3949
3972
|
] });
|
|
3950
3973
|
};
|
|
3951
3974
|
const UserDivider = () => {
|
|
3952
|
-
return /* @__PURE__ */ (0,
|
|
3975
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)("div", { className: `matchid-user-popover-divider` });
|
|
3953
3976
|
};
|
|
3954
3977
|
const [usernameOpen, setUsernameOpen] = (0, import_react26.useState)(false);
|
|
3955
3978
|
const [copied, setCopied] = useCopyClipboard();
|
|
3956
3979
|
const intl = (0, import_react_intl11.useIntl)();
|
|
3957
|
-
return /* @__PURE__ */ (0,
|
|
3958
|
-
/* @__PURE__ */ (0,
|
|
3959
|
-
/* @__PURE__ */ (0,
|
|
3980
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "matchid-user-popover-content", children: [
|
|
3981
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("div", { className: "matchid-user-popover-list", children: [
|
|
3982
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)(UserItem, { onClick: () => {
|
|
3960
3983
|
setCopied(address);
|
|
3961
|
-
}, icon: copied ? /* @__PURE__ */ (0,
|
|
3962
|
-
/* @__PURE__ */ (0,
|
|
3963
|
-
/* @__PURE__ */ (0,
|
|
3984
|
+
}, icon: copied ? /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(CheckIcon, { size: 20, color: "#0ecb81" }) : /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(CopyIcon, { size: 20, color: "var(--icon-color)" }), rightIcon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(CheckIcon, { size: 20, color: "var(--icon-color)" }), children: truncateAddress(address) }),
|
|
3985
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)(UserDivider, {}),
|
|
3986
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)(UserItem, { onClick: () => {
|
|
3964
3987
|
setUsernameOpen(true);
|
|
3965
|
-
}, icon: /* @__PURE__ */ (0,
|
|
3988
|
+
}, icon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(ProfileIcon, { size: 20, color: "var(--icon-color)" }), rightIcon: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(ArrowRightIcon, { size: 20, color: "var(--icon-color)" }), children: username || intl.formatMessage({
|
|
3966
3989
|
id: "setUsername"
|
|
3967
3990
|
}) })
|
|
3968
3991
|
] }),
|
|
3969
|
-
/* @__PURE__ */ (0,
|
|
3970
|
-
/* @__PURE__ */ (0,
|
|
3992
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Button, { onClick: onLogout, loading: logouting, children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(import_react_intl11.FormattedMessage, { id: "disconnect" }) }),
|
|
3993
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)(UsernameModal, { isOpen: usernameOpen, onClose: () => {
|
|
3971
3994
|
setUsernameOpen(false);
|
|
3972
3995
|
}, onSuccess: () => {
|
|
3973
3996
|
setUsernameOpen(false);
|
|
@@ -3978,12 +4001,12 @@ function UserPopover({
|
|
|
3978
4001
|
children,
|
|
3979
4002
|
...props
|
|
3980
4003
|
}) {
|
|
3981
|
-
return /* @__PURE__ */ (0,
|
|
4004
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Popover, { ...props, content: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(UserContent, {}), children });
|
|
3982
4005
|
}
|
|
3983
4006
|
|
|
3984
4007
|
// src/components/LoginButton/index.tsx
|
|
3985
4008
|
var import_react_intl12 = require("react-intl");
|
|
3986
|
-
var
|
|
4009
|
+
var import_jsx_runtime82 = require("react/jsx-runtime");
|
|
3987
4010
|
function LoginButton({
|
|
3988
4011
|
loginRender,
|
|
3989
4012
|
methods,
|
|
@@ -3999,8 +4022,8 @@ function LoginButton({
|
|
|
3999
4022
|
const { isLogin, username } = useUserInfo();
|
|
4000
4023
|
const [loginOpen, setLoginOpen] = (0, import_react27.useState)(false);
|
|
4001
4024
|
if (!isLogin) {
|
|
4002
|
-
return /* @__PURE__ */ (0,
|
|
4003
|
-
/* @__PURE__ */ (0,
|
|
4025
|
+
return /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)(import_jsx_runtime82.Fragment, { children: [
|
|
4026
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)(
|
|
4004
4027
|
LoginModal,
|
|
4005
4028
|
{
|
|
4006
4029
|
methods,
|
|
@@ -4010,15 +4033,15 @@ function LoginButton({
|
|
|
4010
4033
|
onClose: () => setLoginOpen(false)
|
|
4011
4034
|
}
|
|
4012
4035
|
),
|
|
4013
|
-
/* @__PURE__ */ (0,
|
|
4014
|
-
/* @__PURE__ */ (0,
|
|
4015
|
-
/* @__PURE__ */ (0,
|
|
4036
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsxs)(Button, { className: "matchid-unlogin-btn", ...props, highlight: true, onClick: () => setLoginOpen(true), children: [
|
|
4037
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)(UnLoginIcon_default, {}),
|
|
4038
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_react_intl12.FormattedMessage, { id: "login" }) })
|
|
4016
4039
|
] })
|
|
4017
4040
|
] });
|
|
4018
4041
|
}
|
|
4019
|
-
return loginRender ? /* @__PURE__ */ (0,
|
|
4020
|
-
/* @__PURE__ */ (0,
|
|
4021
|
-
/* @__PURE__ */ (0,
|
|
4042
|
+
return loginRender ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_jsx_runtime82.Fragment, { children: loginRender }) : /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(UserPopover, { position: popoverPosition, type: popoverType, gap: popoverGap, children: /* @__PURE__ */ (0, import_jsx_runtime82.jsxs)(Button, { onClick: onLoginClick, className: "matchid-login-btn", ...props, children: [
|
|
4043
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)(LoginIcon_default, {}),
|
|
4044
|
+
/* @__PURE__ */ (0, import_jsx_runtime82.jsx)("span", { children: username ? truncateAddress(username) : "MatchID " + intl.formatMessage({
|
|
4022
4045
|
id: "user"
|
|
4023
4046
|
}) })
|
|
4024
4047
|
] }) });
|
|
@@ -4027,15 +4050,15 @@ function LoginButton({
|
|
|
4027
4050
|
// src/components/UsernameModal/index.tsx
|
|
4028
4051
|
var import_react28 = require("react");
|
|
4029
4052
|
var import_react_intl13 = require("react-intl");
|
|
4030
|
-
var
|
|
4053
|
+
var import_jsx_runtime83 = require("react/jsx-runtime");
|
|
4031
4054
|
var ValidItem = ({
|
|
4032
4055
|
success = false,
|
|
4033
4056
|
text
|
|
4034
4057
|
}) => {
|
|
4035
4058
|
const isDownMd = useDownMd();
|
|
4036
|
-
return /* @__PURE__ */ (0,
|
|
4037
|
-
success ? /* @__PURE__ */ (0,
|
|
4038
|
-
/* @__PURE__ */ (0,
|
|
4059
|
+
return /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: `matchid-valid-status-item matchid-valid-status-${success ? "success" : "error"}`, children: [
|
|
4060
|
+
success ? /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(CheckRoundIcon, { size: isDownMd ? 12 : 16 }) : /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(InfoLineIcon, { size: isDownMd ? 12 : 16 }),
|
|
4061
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)("span", { children: text })
|
|
4039
4062
|
] });
|
|
4040
4063
|
};
|
|
4041
4064
|
function UsernameModal({
|
|
@@ -4083,12 +4106,12 @@ function UsernameModal({
|
|
|
4083
4106
|
}
|
|
4084
4107
|
};
|
|
4085
4108
|
const intl = (0, import_react_intl13.useIntl)();
|
|
4086
|
-
return /* @__PURE__ */ (0,
|
|
4109
|
+
return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(ModalWithHeader, { isOpen: isOpen && isLogin, ...props, title: title || intl.formatMessage({
|
|
4087
4110
|
id: username ? "editUsernameTitle" : "setUsernameTitle"
|
|
4088
|
-
}), children: /* @__PURE__ */ (0,
|
|
4089
|
-
/* @__PURE__ */ (0,
|
|
4111
|
+
}), children: /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: "matchid-username-box", children: [
|
|
4112
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Field, { label: intl.formatMessage({
|
|
4090
4113
|
id: "username"
|
|
4091
|
-
}), error, children: /* @__PURE__ */ (0,
|
|
4114
|
+
}), error, children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
|
|
4092
4115
|
Input,
|
|
4093
4116
|
{
|
|
4094
4117
|
placeholder: intl.formatMessage({
|
|
@@ -4101,8 +4124,8 @@ function UsernameModal({
|
|
|
4101
4124
|
value: val
|
|
4102
4125
|
}
|
|
4103
4126
|
) }),
|
|
4104
|
-
/* @__PURE__ */ (0,
|
|
4105
|
-
/* @__PURE__ */ (0,
|
|
4127
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsxs)("div", { className: "matchid-valid", children: [
|
|
4128
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
|
|
4106
4129
|
ValidItem,
|
|
4107
4130
|
{
|
|
4108
4131
|
success: isValid,
|
|
@@ -4111,36 +4134,21 @@ function UsernameModal({
|
|
|
4111
4134
|
})
|
|
4112
4135
|
}
|
|
4113
4136
|
),
|
|
4114
|
-
/* @__PURE__ */ (0,
|
|
4137
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(ValidItem, { success: isLength, text: intl.formatMessage({
|
|
4115
4138
|
id: "usernameLengthError"
|
|
4116
4139
|
}) })
|
|
4117
4140
|
] }),
|
|
4118
|
-
/* @__PURE__ */ (0,
|
|
4141
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Button, { disabled: !isSafe, loading: isSubmitting, style: {
|
|
4119
4142
|
marginTop: isDownMd ? "36px" : "64px"
|
|
4120
|
-
}, onClick: onSubmit, size: "lg", block: true, highlight: true, children: /* @__PURE__ */ (0,
|
|
4121
|
-
/* @__PURE__ */ (0,
|
|
4143
|
+
}, onClick: onSubmit, size: "lg", block: true, highlight: true, children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_react_intl13.FormattedMessage, { id: "confirm" }) }),
|
|
4144
|
+
/* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Button, { style: {
|
|
4122
4145
|
marginTop: isDownMd ? "12px" : "24px"
|
|
4123
|
-
}, onClick: props.onClose, size: "lg", block: true, children: /* @__PURE__ */ (0,
|
|
4146
|
+
}, onClick: props.onClose, size: "lg", block: true, children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_react_intl13.FormattedMessage, { id: "cancel" }) })
|
|
4124
4147
|
] }) });
|
|
4125
4148
|
}
|
|
4126
4149
|
|
|
4127
|
-
// src/components/
|
|
4128
|
-
var
|
|
4129
|
-
var import_web3 = require("@solana/web3.js");
|
|
4130
|
-
var import_wallet_adapter_react = require("@solana/wallet-adapter-react");
|
|
4131
|
-
var import_wallet_adapter_react_ui = require("@solana/wallet-adapter-react-ui");
|
|
4132
|
-
|
|
4133
|
-
// node_modules/@solana/wallet-adapter-base/lib/esm/types.js
|
|
4134
|
-
var WalletAdapterNetwork;
|
|
4135
|
-
(function(WalletAdapterNetwork2) {
|
|
4136
|
-
WalletAdapterNetwork2["Mainnet"] = "mainnet-beta";
|
|
4137
|
-
WalletAdapterNetwork2["Testnet"] = "testnet";
|
|
4138
|
-
WalletAdapterNetwork2["Devnet"] = "devnet";
|
|
4139
|
-
})(WalletAdapterNetwork || (WalletAdapterNetwork = {}));
|
|
4140
|
-
|
|
4141
|
-
// src/components/SOLModal/index.tsx
|
|
4142
|
-
var import_wallet_adapter_wallets = require("@solana/wallet-adapter-wallets");
|
|
4143
|
-
var import_styles = require("@solana/wallet-adapter-react-ui/styles.css");
|
|
4150
|
+
// src/components/TRONModal/index.tsx
|
|
4151
|
+
var import_react31 = __toESM(require("react"));
|
|
4144
4152
|
var import_react_intl14 = require("react-intl");
|
|
4145
4153
|
|
|
4146
4154
|
// src/components/WalletModalContent/index.tsx
|
|
@@ -4154,7 +4162,7 @@ var walletConnectImage = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEA
|
|
|
4154
4162
|
var walletSigningImage = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAABAsUlEQVR4Xu19CXQUx7X2vCUveS/vJdgx+yaJHQwI8G4wzWIbG2LLNrbxPgnY7CC0SyNpJBAIECAZAbLB8gAyKGGxiFnkGJwmz47xsU0mvyEWoGW0D0jgSeK88L84/7l/fS2V3GrNaDRCEiPpfud8p3qqu6tnpvt+favqVpXJxGAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYbYvCwkKlpKREvXDhglpQUKCKz+qlS5e0z8j3N5aXl6tXrlwJMf4OBoPRDD777LPg7Ozs0MOHD1NiYiLNnTuX7rzrDho5ejj179+f+vbt69ccNGgQBQQE0LBhw2jUqFE0ZswYun3sGBo3cQxNmDiexk+8XaTBIh1LwYLfbY/vcvsnTpyofUbqjXfeeSdNnjyZHnnkEXrxxRcpKSmJfvnLX9KuXbtCz5w5ozgcjmDjs8LoQlBVNcBqtZrFjbfjIYAR/fCHP6Qf/OAH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BwIp8uQkpChb5oG8v/326ydubSnxImjOxXdH3G+chyoCJjU1MfwLycnJhL56o7G7Ix4eiAAM3928giY3D4CeRsFg3jwa701LKO+7Mb85wvjhKRw6dEi9dOkSv/39DZ9++mlGUlKStsqMsc5ufGgkPQmAu4dLn+fpGGbXJDwODAvOysrq0LUJGT4A/bH5+flJcXFxWiuuSXcDjYatZ3NdiO7orjz9tZhdg3g5oLoBbxFrG+zbt88unq8AE8P/gTaBB6Y+QP/5Xz/UbqbRYJldj7jPraGnc9G1jHal6OhotPjbTYzOhUPvHlLnL/iZFg2IBh/jA+PpwTHul3MMGvObY2vaCHw9R3ZVGfObI85pzW9pzTnGPG9szTltRf39R5UQ3cqPPvqotlApRnhyi38nBKK6RH3N/M4776CbjyZMmEB9+/bVBnfIh83kRvkl5cPRUQbQXFuEJ/p6HX8WgNb8/rYiro0uXSwzh1GkmzIyKDs721xQUKB890QxOiUqKyuDEeCTkpISumvXLlq1ahU99NBDdP/99xNi/DFqcNiwYcxOSNw7EEFecNcR4+ErMcz7hRde0Gb22bNnz+nU1FRF/egjxfgcMboYzp8/H/zll1+qvz9/Xj3/1VfqVwYWFRWhu0e9cOGCto20sLBQo3gz8P4ust/Bk3kwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDAaDwWAwGAwGg8FgMBgMBoPBYDAYDN/x/wHjsXZ4EUApzgAAAABJRU5ErkJggg==";
|
|
4155
4163
|
|
|
4156
4164
|
// src/components/WalletModalContent/index.tsx
|
|
4157
|
-
var
|
|
4165
|
+
var import_jsx_runtime84 = require("react/jsx-runtime");
|
|
4158
4166
|
function WalletModalContent({
|
|
4159
4167
|
status,
|
|
4160
4168
|
error,
|
|
@@ -4224,12 +4232,12 @@ function WalletModalContent({
|
|
|
4224
4232
|
statusImage: walletConnectImage
|
|
4225
4233
|
};
|
|
4226
4234
|
}, [visible, connected, status, error, address]);
|
|
4227
|
-
return /* @__PURE__ */ (0,
|
|
4228
|
-
/* @__PURE__ */ (0,
|
|
4229
|
-
/* @__PURE__ */ (0,
|
|
4230
|
-
/* @__PURE__ */ (0,
|
|
4235
|
+
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("div", { className: "matchid-wallet-container", children: /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { className: `matchid-wallet-box`, children: [
|
|
4236
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { className: `matchid-wallet-content`, children: [
|
|
4237
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsx)("img", { src: pageData.statusImage }),
|
|
4238
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsx)("div", { className: pageData.isError ? "text-[#F7585E]" : "", children: pageData.text })
|
|
4231
4239
|
] }),
|
|
4232
|
-
/* @__PURE__ */ (0,
|
|
4240
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
|
|
4233
4241
|
Button,
|
|
4234
4242
|
{
|
|
4235
4243
|
block: true,
|
|
@@ -4243,164 +4251,6 @@ function WalletModalContent({
|
|
|
4243
4251
|
] }) });
|
|
4244
4252
|
}
|
|
4245
4253
|
|
|
4246
|
-
// src/components/SOLModal/index.tsx
|
|
4247
|
-
var import_jsx_runtime84 = require("react/jsx-runtime");
|
|
4248
|
-
function WalletContent({
|
|
4249
|
-
onSuccess,
|
|
4250
|
-
type
|
|
4251
|
-
}) {
|
|
4252
|
-
const { setVisible, visible } = (0, import_wallet_adapter_react_ui.useWalletModal)();
|
|
4253
|
-
const wallet = (0, import_wallet_adapter_react.useWallet)();
|
|
4254
|
-
const { events, login } = useMatch();
|
|
4255
|
-
const [status, setStatus] = (0, import_react30.useState)("");
|
|
4256
|
-
const statusRef = import_react30.default.useRef(status);
|
|
4257
|
-
const [error, setError] = (0, import_react30.useState)("");
|
|
4258
|
-
(0, import_react30.useEffect)(() => {
|
|
4259
|
-
const init = async () => {
|
|
4260
|
-
await wallet.disconnect();
|
|
4261
|
-
setVisible(true);
|
|
4262
|
-
};
|
|
4263
|
-
init();
|
|
4264
|
-
}, []);
|
|
4265
|
-
(0, import_react30.useEffect)(() => {
|
|
4266
|
-
if (wallet.connected) {
|
|
4267
|
-
console.log("wallet.connected", wallet.connected);
|
|
4268
|
-
toLoginInWallet();
|
|
4269
|
-
}
|
|
4270
|
-
}, [wallet.connected]);
|
|
4271
|
-
const toLoginInWallet = async () => {
|
|
4272
|
-
if (statusRef.current) return;
|
|
4273
|
-
const address = wallet.publicKey?.toBase58() || "";
|
|
4274
|
-
try {
|
|
4275
|
-
setStatus("nonce");
|
|
4276
|
-
statusRef.current = "nonce";
|
|
4277
|
-
const res = type == "bind" ? await getWalletInitApi({
|
|
4278
|
-
address,
|
|
4279
|
-
type: "SOL"
|
|
4280
|
-
}) : await getWalletNonceApi({ address, type: "SOL" });
|
|
4281
|
-
if (!isSuccess(res)) {
|
|
4282
|
-
throw new Error(res.message);
|
|
4283
|
-
}
|
|
4284
|
-
const nonce = res.code >= 0 ? res.data.nonce : null;
|
|
4285
|
-
if (nonce) {
|
|
4286
|
-
setStatus("signer");
|
|
4287
|
-
statusRef.current = "signer";
|
|
4288
|
-
const message = "By signing, you are proving you own this wallet and logging in. This does not initiate a transaction or cost any fees.Nonce:" + res.data.nonce;
|
|
4289
|
-
const encodedMessage = new TextEncoder().encode(message);
|
|
4290
|
-
const signedMessage = await wallet.signMessage(encodedMessage);
|
|
4291
|
-
let obj = {
|
|
4292
|
-
type: "SOL",
|
|
4293
|
-
address,
|
|
4294
|
-
signature: Buffer.from(signedMessage).toString("base64"),
|
|
4295
|
-
message,
|
|
4296
|
-
connector_type: "SOL",
|
|
4297
|
-
wallet_client_type: wallet.wallet?.adapter.name || ""
|
|
4298
|
-
};
|
|
4299
|
-
const res1 = type == "bind" ? await toBindWalletApi(obj) : await loginByWalletApi(obj);
|
|
4300
|
-
if (res1) {
|
|
4301
|
-
if (!isSuccess(res1)) {
|
|
4302
|
-
throw new Error(res1.message);
|
|
4303
|
-
}
|
|
4304
|
-
matchlog_default.log(res1);
|
|
4305
|
-
setStatus("success");
|
|
4306
|
-
statusRef.current = "success";
|
|
4307
|
-
if (type == "bind") {
|
|
4308
|
-
events.onBind && events.onBind({
|
|
4309
|
-
type: "sol"
|
|
4310
|
-
});
|
|
4311
|
-
eventManager_default.emit("onBind", {
|
|
4312
|
-
type: "sol"
|
|
4313
|
-
});
|
|
4314
|
-
} else {
|
|
4315
|
-
await login({
|
|
4316
|
-
mid: res1.data.mid,
|
|
4317
|
-
token: `${res1.data.token_type} ${res1.data.access_token}`
|
|
4318
|
-
});
|
|
4319
|
-
}
|
|
4320
|
-
onSuccess && onSuccess();
|
|
4321
|
-
}
|
|
4322
|
-
}
|
|
4323
|
-
} catch (error2) {
|
|
4324
|
-
setStatus("error");
|
|
4325
|
-
setError(error2.message);
|
|
4326
|
-
statusRef.current = "";
|
|
4327
|
-
}
|
|
4328
|
-
};
|
|
4329
|
-
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
|
|
4330
|
-
WalletModalContent,
|
|
4331
|
-
{
|
|
4332
|
-
connected: wallet.connected,
|
|
4333
|
-
disconnect: wallet.disconnect,
|
|
4334
|
-
address: wallet.publicKey?.toBase58(),
|
|
4335
|
-
visible,
|
|
4336
|
-
setVisible,
|
|
4337
|
-
error,
|
|
4338
|
-
setError,
|
|
4339
|
-
status
|
|
4340
|
-
}
|
|
4341
|
-
);
|
|
4342
|
-
}
|
|
4343
|
-
var wallets = [
|
|
4344
|
-
new import_wallet_adapter_wallets.PhantomWalletAdapter(),
|
|
4345
|
-
new import_wallet_adapter_wallets.SolflareWalletAdapter(),
|
|
4346
|
-
new import_wallet_adapter_wallets.WalletConnectWalletAdapter({
|
|
4347
|
-
network: WalletAdapterNetwork.Mainnet,
|
|
4348
|
-
options: {
|
|
4349
|
-
relayUrl: "wss://relay.walletconnect.com"
|
|
4350
|
-
}
|
|
4351
|
-
}),
|
|
4352
|
-
new import_wallet_adapter_wallets.AlphaWalletAdapter(),
|
|
4353
|
-
new import_wallet_adapter_wallets.AvanaWalletAdapter(),
|
|
4354
|
-
new import_wallet_adapter_wallets.BitgetWalletAdapter(),
|
|
4355
|
-
new import_wallet_adapter_wallets.BitpieWalletAdapter(),
|
|
4356
|
-
new import_wallet_adapter_wallets.CloverWalletAdapter(),
|
|
4357
|
-
new import_wallet_adapter_wallets.Coin98WalletAdapter(),
|
|
4358
|
-
new import_wallet_adapter_wallets.CoinbaseWalletAdapter(),
|
|
4359
|
-
new import_wallet_adapter_wallets.CoinhubWalletAdapter(),
|
|
4360
|
-
new import_wallet_adapter_wallets.FractalWalletAdapter(),
|
|
4361
|
-
new import_wallet_adapter_wallets.HuobiWalletAdapter(),
|
|
4362
|
-
new import_wallet_adapter_wallets.HyperPayWalletAdapter(),
|
|
4363
|
-
new import_wallet_adapter_wallets.KeystoneWalletAdapter(),
|
|
4364
|
-
new import_wallet_adapter_wallets.KrystalWalletAdapter(),
|
|
4365
|
-
new import_wallet_adapter_wallets.LedgerWalletAdapter(),
|
|
4366
|
-
new import_wallet_adapter_wallets.MathWalletAdapter(),
|
|
4367
|
-
new import_wallet_adapter_wallets.NekoWalletAdapter(),
|
|
4368
|
-
new import_wallet_adapter_wallets.NightlyWalletAdapter(),
|
|
4369
|
-
new import_wallet_adapter_wallets.NufiWalletAdapter(),
|
|
4370
|
-
new import_wallet_adapter_wallets.OntoWalletAdapter(),
|
|
4371
|
-
new import_wallet_adapter_wallets.ParticleAdapter(),
|
|
4372
|
-
new import_wallet_adapter_wallets.SafePalWalletAdapter(),
|
|
4373
|
-
new import_wallet_adapter_wallets.SaifuWalletAdapter(),
|
|
4374
|
-
new import_wallet_adapter_wallets.SalmonWalletAdapter(),
|
|
4375
|
-
new import_wallet_adapter_wallets.SkyWalletAdapter(),
|
|
4376
|
-
new import_wallet_adapter_wallets.SolongWalletAdapter(),
|
|
4377
|
-
new import_wallet_adapter_wallets.SpotWalletAdapter(),
|
|
4378
|
-
new import_wallet_adapter_wallets.TokenaryWalletAdapter(),
|
|
4379
|
-
new import_wallet_adapter_wallets.TokenPocketWalletAdapter(),
|
|
4380
|
-
new import_wallet_adapter_wallets.TorusWalletAdapter(),
|
|
4381
|
-
new import_wallet_adapter_wallets.TrustWalletAdapter(),
|
|
4382
|
-
new import_wallet_adapter_wallets.XDEFIWalletAdapter()
|
|
4383
|
-
];
|
|
4384
|
-
function SOLConnectModal({
|
|
4385
|
-
type = "login",
|
|
4386
|
-
onSuccess,
|
|
4387
|
-
...props
|
|
4388
|
-
}) {
|
|
4389
|
-
const intl = (0, import_react_intl14.useIntl)();
|
|
4390
|
-
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(ModalWithHeader, { ...props, title: props.title || intl.formatMessage({
|
|
4391
|
-
id: type == "bind" ? "bindWith" : "loginWith"
|
|
4392
|
-
}, {
|
|
4393
|
-
name: "SOL"
|
|
4394
|
-
}), children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_wallet_adapter_react.ConnectionProvider, { endpoint: (0, import_web3.clusterApiUrl)("devnet"), children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_wallet_adapter_react.WalletProvider, { wallets, autoConnect: true, children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_wallet_adapter_react_ui.WalletModalProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(WalletContent, { onSuccess, type }) }) }) }) });
|
|
4395
|
-
}
|
|
4396
|
-
function SOLModal(props) {
|
|
4397
|
-
return props.isOpen && /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(SOLConnectModal, { ...props });
|
|
4398
|
-
}
|
|
4399
|
-
|
|
4400
|
-
// src/components/TRONModal/index.tsx
|
|
4401
|
-
var import_react32 = __toESM(require("react"));
|
|
4402
|
-
var import_react_intl15 = require("react-intl");
|
|
4403
|
-
|
|
4404
4254
|
// src/lib/tron/TronLinkAdapter.ts
|
|
4405
4255
|
var TronLinkAdapter = class {
|
|
4406
4256
|
constructor() {
|
|
@@ -4432,7 +4282,7 @@ var TronLinkAdapter = class {
|
|
|
4432
4282
|
};
|
|
4433
4283
|
|
|
4434
4284
|
// src/hooks/useTRONWallet.ts
|
|
4435
|
-
var
|
|
4285
|
+
var import_react30 = require("react");
|
|
4436
4286
|
|
|
4437
4287
|
// src/lib/tron/BitgetAdapter.ts
|
|
4438
4288
|
var BitgetAdapter = class {
|
|
@@ -4476,12 +4326,12 @@ var OKXAdapter = class {
|
|
|
4476
4326
|
|
|
4477
4327
|
// src/hooks/useTRONWallet.ts
|
|
4478
4328
|
var useTRONWallet = () => {
|
|
4479
|
-
const
|
|
4480
|
-
const [installedWallets, setInstalledWallets] = (0,
|
|
4481
|
-
const [address, setAddress] = (0,
|
|
4482
|
-
(0,
|
|
4329
|
+
const wallets = [new TronLinkAdapter(), new BitgetAdapter(), new OKXAdapter()];
|
|
4330
|
+
const [installedWallets, setInstalledWallets] = (0, import_react30.useState)([]);
|
|
4331
|
+
const [address, setAddress] = (0, import_react30.useState)(null);
|
|
4332
|
+
(0, import_react30.useEffect)(() => {
|
|
4483
4333
|
const getInstalled = async () => {
|
|
4484
|
-
const installed = await Promise.all(
|
|
4334
|
+
const installed = await Promise.all(wallets.map((wallet2) => wallet2.isInstalled().then((isInstalled) => ({
|
|
4485
4335
|
wallet: wallet2,
|
|
4486
4336
|
isInstalled
|
|
4487
4337
|
}))));
|
|
@@ -4489,18 +4339,18 @@ var useTRONWallet = () => {
|
|
|
4489
4339
|
};
|
|
4490
4340
|
getInstalled();
|
|
4491
4341
|
}, []);
|
|
4492
|
-
const [wallet, chooseWallet] = (0,
|
|
4342
|
+
const [wallet, chooseWallet] = (0, import_react30.useState)(null);
|
|
4493
4343
|
const onConnect = async () => {
|
|
4494
4344
|
setAddress(await wallet.connect());
|
|
4495
4345
|
};
|
|
4496
|
-
(0,
|
|
4346
|
+
(0, import_react30.useEffect)(() => {
|
|
4497
4347
|
if (!wallet) {
|
|
4498
4348
|
setAddress(null);
|
|
4499
4349
|
}
|
|
4500
4350
|
}, [wallet]);
|
|
4501
4351
|
return {
|
|
4502
4352
|
installedWallets,
|
|
4503
|
-
wallets
|
|
4353
|
+
wallets,
|
|
4504
4354
|
chooseWallet,
|
|
4505
4355
|
wallet,
|
|
4506
4356
|
address,
|
|
@@ -4516,18 +4366,18 @@ function TRONConnectModal({
|
|
|
4516
4366
|
...props
|
|
4517
4367
|
}) {
|
|
4518
4368
|
const isDownMd = useDownMd();
|
|
4519
|
-
const intl = (0,
|
|
4520
|
-
const { wallets
|
|
4369
|
+
const intl = (0, import_react_intl14.useIntl)();
|
|
4370
|
+
const { wallets, installedWallets, chooseWallet, wallet, address, onConnect } = useTRONWallet();
|
|
4521
4371
|
const iconMaps = {
|
|
4522
4372
|
tronlink: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(TronLinkIcon, { size: isDownMd ? 36 : 40 }),
|
|
4523
4373
|
bitget: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(BitgetIcon, { size: isDownMd ? 36 : 40 }),
|
|
4524
4374
|
okx: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(OKXIcon, { size: isDownMd ? 36 : 40 })
|
|
4525
4375
|
};
|
|
4526
4376
|
const { events, login } = useMatch();
|
|
4527
|
-
const [status, setStatus] = (0,
|
|
4528
|
-
const statusRef =
|
|
4529
|
-
const [error, setError] = (0,
|
|
4530
|
-
const connected = (0,
|
|
4377
|
+
const [status, setStatus] = (0, import_react31.useState)("");
|
|
4378
|
+
const statusRef = import_react31.default.useRef(status);
|
|
4379
|
+
const [error, setError] = (0, import_react31.useState)("");
|
|
4380
|
+
const connected = (0, import_react31.useMemo)(() => {
|
|
4531
4381
|
return !!address;
|
|
4532
4382
|
}, [address]);
|
|
4533
4383
|
const disconnect = async () => {
|
|
@@ -4582,7 +4432,7 @@ function TRONConnectModal({
|
|
|
4582
4432
|
});
|
|
4583
4433
|
} else {
|
|
4584
4434
|
await login({
|
|
4585
|
-
mid: res1.data.mid,
|
|
4435
|
+
// mid: res1.data.mid,
|
|
4586
4436
|
token: `${res1.data.token_type} ${res1.data.access_token}`
|
|
4587
4437
|
});
|
|
4588
4438
|
}
|
|
@@ -4595,7 +4445,7 @@ function TRONConnectModal({
|
|
|
4595
4445
|
statusRef.current = "";
|
|
4596
4446
|
}
|
|
4597
4447
|
};
|
|
4598
|
-
(0,
|
|
4448
|
+
(0, import_react31.useEffect)(() => {
|
|
4599
4449
|
if (wallet) {
|
|
4600
4450
|
console.log("onConnect");
|
|
4601
4451
|
onConnect();
|
|
@@ -4603,12 +4453,12 @@ function TRONConnectModal({
|
|
|
4603
4453
|
setStatus("");
|
|
4604
4454
|
}
|
|
4605
4455
|
}, [wallet]);
|
|
4606
|
-
(0,
|
|
4456
|
+
(0, import_react31.useEffect)(() => {
|
|
4607
4457
|
if (address) {
|
|
4608
4458
|
toLoginInWallet();
|
|
4609
4459
|
}
|
|
4610
4460
|
}, [address]);
|
|
4611
|
-
(0,
|
|
4461
|
+
(0, import_react31.useEffect)(() => {
|
|
4612
4462
|
if (!props.isOpen) {
|
|
4613
4463
|
disconnect();
|
|
4614
4464
|
}
|
|
@@ -4644,7 +4494,7 @@ function TRONConnectModal({
|
|
|
4644
4494
|
wallet2.walletKey
|
|
4645
4495
|
);
|
|
4646
4496
|
}),
|
|
4647
|
-
|
|
4497
|
+
wallets.filter((wallet2) => !installedWallets.find((installedWallet) => installedWallet.walletKey == wallet2.walletKey)).map((wallet2) => {
|
|
4648
4498
|
return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
4649
4499
|
RecommendItem,
|
|
4650
4500
|
{
|
|
@@ -4666,24 +4516,24 @@ function TRONModal(props) {
|
|
|
4666
4516
|
}
|
|
4667
4517
|
|
|
4668
4518
|
// src/components/TONModal/index.tsx
|
|
4669
|
-
var
|
|
4670
|
-
var
|
|
4519
|
+
var import_react32 = __toESM(require("react"));
|
|
4520
|
+
var import_react_intl15 = require("react-intl");
|
|
4671
4521
|
var import_ui_react = require("@tonconnect/ui-react");
|
|
4672
4522
|
var import_jsx_runtime86 = require("react/jsx-runtime");
|
|
4673
|
-
function
|
|
4523
|
+
function WalletContent({
|
|
4674
4524
|
onSuccess,
|
|
4675
4525
|
type
|
|
4676
4526
|
}) {
|
|
4677
4527
|
const { events, login } = useMatch();
|
|
4678
|
-
const [connected, setConnected] = (0,
|
|
4528
|
+
const [connected, setConnected] = (0, import_react32.useState)(false);
|
|
4679
4529
|
const wallet = (0, import_ui_react.useTonWallet)();
|
|
4680
4530
|
const userFriendlyAddress = (0, import_ui_react.useTonAddress)();
|
|
4681
4531
|
const [tonConnectUI] = (0, import_ui_react.useTonConnectUI)();
|
|
4682
4532
|
const { state, open, close } = (0, import_ui_react.useTonConnectModal)();
|
|
4683
|
-
const [status, setStatus] = (0,
|
|
4684
|
-
const statusRef =
|
|
4685
|
-
const [error, setError] = (0,
|
|
4686
|
-
(0,
|
|
4533
|
+
const [status, setStatus] = (0, import_react32.useState)("");
|
|
4534
|
+
const statusRef = import_react32.default.useRef(status);
|
|
4535
|
+
const [error, setError] = (0, import_react32.useState)("");
|
|
4536
|
+
(0, import_react32.useEffect)(() => {
|
|
4687
4537
|
const init = async () => {
|
|
4688
4538
|
if (tonConnectUI.connected) {
|
|
4689
4539
|
await tonConnectUI.disconnect();
|
|
@@ -4740,7 +4590,7 @@ function WalletContent2({
|
|
|
4740
4590
|
});
|
|
4741
4591
|
} else {
|
|
4742
4592
|
await login({
|
|
4743
|
-
mid: res1.data.mid,
|
|
4593
|
+
// mid: res1.data.mid,
|
|
4744
4594
|
token: `${res1.data.token_type} ${res1.data.access_token}`
|
|
4745
4595
|
});
|
|
4746
4596
|
}
|
|
@@ -4756,7 +4606,7 @@ function WalletContent2({
|
|
|
4756
4606
|
}
|
|
4757
4607
|
});
|
|
4758
4608
|
}, []);
|
|
4759
|
-
(0,
|
|
4609
|
+
(0, import_react32.useEffect)(() => {
|
|
4760
4610
|
if (wallet) {
|
|
4761
4611
|
setConnected(true);
|
|
4762
4612
|
console.log("Wallet connected:", wallet);
|
|
@@ -4767,7 +4617,7 @@ function WalletContent2({
|
|
|
4767
4617
|
setStatus("");
|
|
4768
4618
|
}
|
|
4769
4619
|
}, [wallet]);
|
|
4770
|
-
(0,
|
|
4620
|
+
(0, import_react32.useEffect)(() => {
|
|
4771
4621
|
console.log({
|
|
4772
4622
|
state,
|
|
4773
4623
|
wallet
|
|
@@ -4827,7 +4677,7 @@ function TONConnectModal({
|
|
|
4827
4677
|
onSuccess,
|
|
4828
4678
|
...props
|
|
4829
4679
|
}) {
|
|
4830
|
-
const intl = (0,
|
|
4680
|
+
const intl = (0, import_react_intl15.useIntl)();
|
|
4831
4681
|
const { endpoints, appid } = useLocalStore_default();
|
|
4832
4682
|
const manifestUrl = `${endpoints.back}api/v1/wallet/ton?appid=${appid}&url=` + encodeURIComponent(window.location.origin);
|
|
4833
4683
|
return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(ModalWithHeader, { ...props, title: props.title || intl.formatMessage({
|
|
@@ -4838,7 +4688,7 @@ function TONConnectModal({
|
|
|
4838
4688
|
import_ui_react.TonConnectUIProvider,
|
|
4839
4689
|
{
|
|
4840
4690
|
manifestUrl,
|
|
4841
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
4691
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(WalletContent, { onSuccess, type })
|
|
4842
4692
|
}
|
|
4843
4693
|
) });
|
|
4844
4694
|
}
|
|
@@ -4847,8 +4697,8 @@ function TONModal(props) {
|
|
|
4847
4697
|
}
|
|
4848
4698
|
|
|
4849
4699
|
// src/components/BTCModal/index.tsx
|
|
4850
|
-
var
|
|
4851
|
-
var
|
|
4700
|
+
var import_react34 = __toESM(require("react"));
|
|
4701
|
+
var import_react_intl16 = require("react-intl");
|
|
4852
4702
|
|
|
4853
4703
|
// src/lib/btc/UnisatAdapter.ts
|
|
4854
4704
|
var UnisatAdapter = class {
|
|
@@ -4988,7 +4838,7 @@ var LeatherAdapter = class {
|
|
|
4988
4838
|
return response.result.addresses[0].address;
|
|
4989
4839
|
}
|
|
4990
4840
|
async signMessage(message) {
|
|
4991
|
-
if (!await this.isInstalled()) throw new Error("
|
|
4841
|
+
if (!await this.isInstalled()) throw new Error("Leather Wallet is not installed");
|
|
4992
4842
|
const response = await window.LeatherProvider?.request("signMessage", { message });
|
|
4993
4843
|
matchlog_default.log("response", response);
|
|
4994
4844
|
return response.result.signature;
|
|
@@ -4996,14 +4846,49 @@ var LeatherAdapter = class {
|
|
|
4996
4846
|
};
|
|
4997
4847
|
|
|
4998
4848
|
// src/hooks/useBTCWallet.ts
|
|
4999
|
-
var
|
|
4849
|
+
var import_react33 = require("react");
|
|
4850
|
+
|
|
4851
|
+
// src/lib/btc/PhantomAdapter.ts
|
|
4852
|
+
var PhantomAdapter = class {
|
|
4853
|
+
constructor() {
|
|
4854
|
+
this.name = "Phantom Wallet";
|
|
4855
|
+
this.website = "https://www.phantom.com/";
|
|
4856
|
+
this.walletKey = "phantom";
|
|
4857
|
+
}
|
|
4858
|
+
async isInstalled() {
|
|
4859
|
+
return typeof window.phantom !== "undefined" && typeof window.phantom.bitcoin !== "undefined";
|
|
4860
|
+
}
|
|
4861
|
+
async connect() {
|
|
4862
|
+
if (!await this.isInstalled()) throw new Error("Phantom Wallet is not installed");
|
|
4863
|
+
const response = await window.phantom.bitcoin.requestAccounts();
|
|
4864
|
+
const ordinalAddress = response.find((n) => n.purpose == "ordinals");
|
|
4865
|
+
matchlog_default.log("Addresses:", ordinalAddress);
|
|
4866
|
+
if (!ordinalAddress) {
|
|
4867
|
+
throw new Error("No addresses found in Phantom Wallet");
|
|
4868
|
+
}
|
|
4869
|
+
return ordinalAddress.address;
|
|
4870
|
+
}
|
|
4871
|
+
async signMessage(message) {
|
|
4872
|
+
if (!await this.isInstalled()) throw new Error("Phantom Wallet is not installed");
|
|
4873
|
+
const address = await this.connect();
|
|
4874
|
+
try {
|
|
4875
|
+
const { signature } = await window.phantom.bitcoin.signMessage(address, new TextEncoder().encode(message));
|
|
4876
|
+
return bytesToBase64(signature);
|
|
4877
|
+
} catch (error) {
|
|
4878
|
+
console.error(error);
|
|
4879
|
+
throw error;
|
|
4880
|
+
}
|
|
4881
|
+
}
|
|
4882
|
+
};
|
|
4883
|
+
|
|
4884
|
+
// src/hooks/useBTCWallet.ts
|
|
5000
4885
|
var useBTCWallet = () => {
|
|
5001
|
-
const
|
|
5002
|
-
const [installedWallets, setInstalledWallets] = (0,
|
|
5003
|
-
const [address, setAddress] = (0,
|
|
5004
|
-
(0,
|
|
4886
|
+
const wallets = [new UnisatAdapter(), new XverseAdapter(), new LeatherAdapter(), new PhantomAdapter()];
|
|
4887
|
+
const [installedWallets, setInstalledWallets] = (0, import_react33.useState)([]);
|
|
4888
|
+
const [address, setAddress] = (0, import_react33.useState)(null);
|
|
4889
|
+
(0, import_react33.useEffect)(() => {
|
|
5005
4890
|
const getInstalled = async () => {
|
|
5006
|
-
const installed = await Promise.all(
|
|
4891
|
+
const installed = await Promise.all(wallets.map((wallet2) => wallet2.isInstalled().then((isInstalled) => ({
|
|
5007
4892
|
wallet: wallet2,
|
|
5008
4893
|
isInstalled
|
|
5009
4894
|
}))));
|
|
@@ -5011,18 +4896,18 @@ var useBTCWallet = () => {
|
|
|
5011
4896
|
};
|
|
5012
4897
|
getInstalled();
|
|
5013
4898
|
}, []);
|
|
5014
|
-
const [wallet, chooseWallet] = (0,
|
|
4899
|
+
const [wallet, chooseWallet] = (0, import_react33.useState)(null);
|
|
5015
4900
|
const onConnect = async () => {
|
|
5016
4901
|
setAddress(await wallet.connect());
|
|
5017
4902
|
};
|
|
5018
|
-
(0,
|
|
4903
|
+
(0, import_react33.useEffect)(() => {
|
|
5019
4904
|
if (!wallet) {
|
|
5020
4905
|
setAddress(null);
|
|
5021
4906
|
}
|
|
5022
4907
|
}, [wallet]);
|
|
5023
4908
|
return {
|
|
5024
4909
|
installedWallets,
|
|
5025
|
-
wallets
|
|
4910
|
+
wallets,
|
|
5026
4911
|
chooseWallet,
|
|
5027
4912
|
wallet,
|
|
5028
4913
|
address,
|
|
@@ -5038,18 +4923,19 @@ function BTCConnectModal({
|
|
|
5038
4923
|
...props
|
|
5039
4924
|
}) {
|
|
5040
4925
|
const isDownMd = useDownMd();
|
|
5041
|
-
const intl = (0,
|
|
5042
|
-
const { wallets
|
|
4926
|
+
const intl = (0, import_react_intl16.useIntl)();
|
|
4927
|
+
const { wallets, installedWallets, chooseWallet, wallet, address, onConnect } = useBTCWallet();
|
|
5043
4928
|
const iconMaps = {
|
|
5044
4929
|
leather: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(LeatherIcon, { size: isDownMd ? 36 : 40 }),
|
|
5045
4930
|
unisat: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(UnisatIcon, { size: isDownMd ? 36 : 40 }),
|
|
5046
|
-
xverse: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(XverseIcon, { size: isDownMd ? 36 : 40 })
|
|
4931
|
+
xverse: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(XverseIcon, { size: isDownMd ? 36 : 40 }),
|
|
4932
|
+
phantom: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(PhantomIcon, { size: isDownMd ? 36 : 40 })
|
|
5047
4933
|
};
|
|
5048
4934
|
const { events, login } = useMatch();
|
|
5049
|
-
const [status, setStatus] = (0,
|
|
5050
|
-
const statusRef =
|
|
5051
|
-
const [error, setError] = (0,
|
|
5052
|
-
const connected = (0,
|
|
4935
|
+
const [status, setStatus] = (0, import_react34.useState)("");
|
|
4936
|
+
const statusRef = import_react34.default.useRef(status);
|
|
4937
|
+
const [error, setError] = (0, import_react34.useState)("");
|
|
4938
|
+
const connected = (0, import_react34.useMemo)(() => {
|
|
5053
4939
|
return !!address;
|
|
5054
4940
|
}, [address]);
|
|
5055
4941
|
const disconnect = async () => {
|
|
@@ -5099,7 +4985,7 @@ function BTCConnectModal({
|
|
|
5099
4985
|
});
|
|
5100
4986
|
} else {
|
|
5101
4987
|
await login({
|
|
5102
|
-
mid: res1.data.mid,
|
|
4988
|
+
// mid: res1.data.mid,
|
|
5103
4989
|
token: `${res1.data.token_type} ${res1.data.access_token}`
|
|
5104
4990
|
});
|
|
5105
4991
|
}
|
|
@@ -5113,7 +4999,7 @@ function BTCConnectModal({
|
|
|
5113
4999
|
statusRef.current = "";
|
|
5114
5000
|
}
|
|
5115
5001
|
};
|
|
5116
|
-
(0,
|
|
5002
|
+
(0, import_react34.useEffect)(() => {
|
|
5117
5003
|
if (wallet) {
|
|
5118
5004
|
console.log("onConnect");
|
|
5119
5005
|
try {
|
|
@@ -5126,12 +5012,12 @@ function BTCConnectModal({
|
|
|
5126
5012
|
setStatus("");
|
|
5127
5013
|
}
|
|
5128
5014
|
}, [wallet]);
|
|
5129
|
-
(0,
|
|
5015
|
+
(0, import_react34.useEffect)(() => {
|
|
5130
5016
|
if (address) {
|
|
5131
5017
|
toLoginInWallet();
|
|
5132
5018
|
}
|
|
5133
5019
|
}, [address]);
|
|
5134
|
-
(0,
|
|
5020
|
+
(0, import_react34.useEffect)(() => {
|
|
5135
5021
|
if (!props.isOpen) {
|
|
5136
5022
|
disconnect();
|
|
5137
5023
|
}
|
|
@@ -5174,7 +5060,7 @@ function BTCConnectModal({
|
|
|
5174
5060
|
wallet2.walletKey
|
|
5175
5061
|
);
|
|
5176
5062
|
}),
|
|
5177
|
-
|
|
5063
|
+
wallets.filter((wallet2) => !installedWallets.find((installedWallet) => installedWallet.walletKey == wallet2.walletKey)).map((wallet2) => {
|
|
5178
5064
|
return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
5179
5065
|
RecommendItem,
|
|
5180
5066
|
{
|
|
@@ -5196,19 +5082,19 @@ function BTCModal(props) {
|
|
|
5196
5082
|
}
|
|
5197
5083
|
|
|
5198
5084
|
// src/components/WalletModal/index.tsx
|
|
5199
|
-
var
|
|
5200
|
-
var
|
|
5085
|
+
var import_react35 = require("react");
|
|
5086
|
+
var import_react_intl17 = require("react-intl");
|
|
5201
5087
|
var import_jsx_runtime88 = require("react/jsx-runtime");
|
|
5202
5088
|
function WalletConnectModal({
|
|
5203
5089
|
type,
|
|
5204
5090
|
methods: _methods,
|
|
5205
5091
|
...props
|
|
5206
5092
|
}) {
|
|
5207
|
-
const intl = (0,
|
|
5093
|
+
const intl = (0, import_react_intl17.useIntl)();
|
|
5208
5094
|
const { walletMap } = useWalletConfig();
|
|
5209
5095
|
const { bind, login } = useUserInfo();
|
|
5210
5096
|
const config = useAppConfig();
|
|
5211
|
-
const methods = (0,
|
|
5097
|
+
const methods = (0, import_react35.useMemo)(() => {
|
|
5212
5098
|
if (_methods) return _methods;
|
|
5213
5099
|
if (!config.platform) {
|
|
5214
5100
|
return [];
|
|
@@ -5240,11 +5126,11 @@ function WalletModal(props) {
|
|
|
5240
5126
|
}
|
|
5241
5127
|
|
|
5242
5128
|
// src/components/AlphaAvatar/index.tsx
|
|
5243
|
-
var
|
|
5129
|
+
var import_react36 = require("react");
|
|
5244
5130
|
var import_jsx_runtime89 = require("react/jsx-runtime");
|
|
5245
5131
|
function AlphaAvatar2({ name, size = 40, className = "" }) {
|
|
5246
|
-
const [avatar, setAvatar] = (0,
|
|
5247
|
-
(0,
|
|
5132
|
+
const [avatar, setAvatar] = (0, import_react36.useState)(void 0);
|
|
5133
|
+
(0, import_react36.useEffect)(() => {
|
|
5248
5134
|
if (name) {
|
|
5249
5135
|
const char = name[0].toUpperCase();
|
|
5250
5136
|
setAvatar(char);
|
|
@@ -5341,9 +5227,9 @@ function WalletAsset({
|
|
|
5341
5227
|
}
|
|
5342
5228
|
|
|
5343
5229
|
// src/components/TokenSend/index.tsx
|
|
5344
|
-
var
|
|
5230
|
+
var import_react37 = require("react");
|
|
5345
5231
|
var import_viem11 = require("viem");
|
|
5346
|
-
var
|
|
5232
|
+
var import_react_intl18 = require("react-intl");
|
|
5347
5233
|
var import_jsx_runtime91 = require("react/jsx-runtime");
|
|
5348
5234
|
function Input2({
|
|
5349
5235
|
onChange,
|
|
@@ -5376,25 +5262,25 @@ function TokenSend({
|
|
|
5376
5262
|
onBack
|
|
5377
5263
|
}) {
|
|
5378
5264
|
const { list: chainList } = useMatchChain();
|
|
5379
|
-
const intl = (0,
|
|
5265
|
+
const intl = (0, import_react_intl18.useIntl)();
|
|
5380
5266
|
const { createWalletClient: createWalletClient2 } = useWallet();
|
|
5381
5267
|
const isNative = token.address.toLowerCase() == NATIVE_TOKEN_ADDRESS;
|
|
5382
|
-
const chain = (0,
|
|
5268
|
+
const chain = (0, import_react37.useMemo)(() => {
|
|
5383
5269
|
return chainList?.find((m) => m.id.toString() === token.chain_id);
|
|
5384
5270
|
}, [chainList, token.chain_id]);
|
|
5385
|
-
const walletClient = (0,
|
|
5271
|
+
const walletClient = (0, import_react37.useMemo)(() => {
|
|
5386
5272
|
return createWalletClient2({
|
|
5387
5273
|
// @ts-ignore
|
|
5388
5274
|
chain: (0, import_viem11.defineChain)(chain),
|
|
5389
5275
|
transport: (0, import_viem11.http)()
|
|
5390
5276
|
});
|
|
5391
5277
|
}, [chain]);
|
|
5392
|
-
const [amount, setAmount] = (0,
|
|
5393
|
-
const [address, setAddress] = (0,
|
|
5394
|
-
const [loading, setLoading] = (0,
|
|
5395
|
-
const [sending, setSending] = (0,
|
|
5396
|
-
const [txError, setTxError] = (0,
|
|
5397
|
-
const transaction = (0,
|
|
5278
|
+
const [amount, setAmount] = (0, import_react37.useState)("");
|
|
5279
|
+
const [address, setAddress] = (0, import_react37.useState)("");
|
|
5280
|
+
const [loading, setLoading] = (0, import_react37.useState)(false);
|
|
5281
|
+
const [sending, setSending] = (0, import_react37.useState)(false);
|
|
5282
|
+
const [txError, setTxError] = (0, import_react37.useState)("");
|
|
5283
|
+
const transaction = (0, import_react37.useMemo)(() => {
|
|
5398
5284
|
const reg = /^0x[a-fA-F0-9]{40}$/;
|
|
5399
5285
|
if (!amount || !address || !reg.test(address)) {
|
|
5400
5286
|
return;
|
|
@@ -5425,7 +5311,7 @@ function TokenSend({
|
|
|
5425
5311
|
setLoading(false);
|
|
5426
5312
|
}
|
|
5427
5313
|
};
|
|
5428
|
-
const error = (0,
|
|
5314
|
+
const error = (0, import_react37.useMemo)(() => {
|
|
5429
5315
|
setTxError("");
|
|
5430
5316
|
let amountError = "";
|
|
5431
5317
|
let addressError = "";
|
|
@@ -5468,7 +5354,7 @@ function TokenSend({
|
|
|
5468
5354
|
setAmount(value);
|
|
5469
5355
|
}
|
|
5470
5356
|
};
|
|
5471
|
-
const canSend = (0,
|
|
5357
|
+
const canSend = (0, import_react37.useMemo)(() => {
|
|
5472
5358
|
return !error.amount && !error.address && amount && address;
|
|
5473
5359
|
}, [error]);
|
|
5474
5360
|
const onNext = async () => {
|
|
@@ -5478,7 +5364,7 @@ function TokenSend({
|
|
|
5478
5364
|
}
|
|
5479
5365
|
onClose();
|
|
5480
5366
|
};
|
|
5481
|
-
(0,
|
|
5367
|
+
(0, import_react37.useEffect)(() => {
|
|
5482
5368
|
const receiveMessage = (event) => {
|
|
5483
5369
|
if (event.data) {
|
|
5484
5370
|
if (event.data.source == "match-wallet") {
|
|
@@ -5494,11 +5380,11 @@ function TokenSend({
|
|
|
5494
5380
|
window.removeEventListener("message", receiveMessage);
|
|
5495
5381
|
};
|
|
5496
5382
|
}, []);
|
|
5497
|
-
return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ModalDrawer, { isOpen: true, onClose, zIndex, title: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5383
|
+
return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ModalDrawer, { isOpen: true, onClose, zIndex, title: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_react_intl18.FormattedMessage, { id: "send" }), onBack, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-send-box`, children: [
|
|
5498
5384
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: "matchid-token-send-content", children: [
|
|
5499
5385
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-amount-content`, children: [
|
|
5500
5386
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-amount-header`, children: [
|
|
5501
|
-
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-amount-title`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5387
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-amount-title`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_react_intl18.FormattedMessage, { id: "amount" }) }),
|
|
5502
5388
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-amount-chain`, children: [
|
|
5503
5389
|
token.icon ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5504
5390
|
"img",
|
|
@@ -5526,7 +5412,7 @@ function TokenSend({
|
|
|
5526
5412
|
),
|
|
5527
5413
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-amount-footer`, children: [
|
|
5528
5414
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-amount-title`, children: [
|
|
5529
|
-
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5415
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_react_intl18.FormattedMessage, { id: "balance" }),
|
|
5530
5416
|
":"
|
|
5531
5417
|
] }),
|
|
5532
5418
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-amount-value`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(NumberFormatter, { value: token.balance, tFixNum: 10, suffix: " " + token.symbol }) })
|
|
@@ -5534,7 +5420,7 @@ function TokenSend({
|
|
|
5534
5420
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(TransferIcon, { className: "matchid-token-amount-transfer" })
|
|
5535
5421
|
] }),
|
|
5536
5422
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: `matchid-token-address-content`, children: [
|
|
5537
|
-
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-address-header`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-address-title`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5423
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-address-header`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: `matchid-token-address-title`, children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_react_intl18.FormattedMessage, { id: "receiveTitle" }) }) }),
|
|
5538
5424
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5539
5425
|
Input2,
|
|
5540
5426
|
{
|
|
@@ -5560,14 +5446,14 @@ function TokenSend({
|
|
|
5560
5446
|
disabled: !canSend || !!txError,
|
|
5561
5447
|
onClick: onNext,
|
|
5562
5448
|
loading: loading || sending,
|
|
5563
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
5449
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_react_intl18.FormattedMessage, { id: "next" })
|
|
5564
5450
|
}
|
|
5565
5451
|
)
|
|
5566
5452
|
] }) });
|
|
5567
5453
|
}
|
|
5568
5454
|
|
|
5569
5455
|
// src/components/TokenDetail/index.tsx
|
|
5570
|
-
var
|
|
5456
|
+
var import_react_intl19 = require("react-intl");
|
|
5571
5457
|
var import_jsx_runtime92 = require("react/jsx-runtime");
|
|
5572
5458
|
function TokenDetail({
|
|
5573
5459
|
onClose,
|
|
@@ -5584,7 +5470,7 @@ function TokenDetail({
|
|
|
5584
5470
|
}, onBack: props.close, zIndex: props.zIndex, token });
|
|
5585
5471
|
});
|
|
5586
5472
|
};
|
|
5587
|
-
const intl = (0,
|
|
5473
|
+
const intl = (0, import_react_intl19.useIntl)();
|
|
5588
5474
|
return /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(ModalDrawer, { isOpen: true, title: intl.formatMessage({
|
|
5589
5475
|
id: "tokenDetails"
|
|
5590
5476
|
}), onClose, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { className: `matchid-token-detail`, children: [
|
|
@@ -5605,13 +5491,13 @@ function TokenDetail({
|
|
|
5605
5491
|
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { className: "matchid-token-contract-address", children: token.address })
|
|
5606
5492
|
] })
|
|
5607
5493
|
] }),
|
|
5608
|
-
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(Button, { size: "lg", block: true, highlight: true, onClick: onSend, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
|
|
5494
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(Button, { size: "lg", block: true, highlight: true, onClick: onSend, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_react_intl19.FormattedMessage, { id: "send" }) })
|
|
5609
5495
|
] }) });
|
|
5610
5496
|
}
|
|
5611
5497
|
|
|
5612
5498
|
// src/components/TokenSendList/index.tsx
|
|
5613
|
-
var
|
|
5614
|
-
var
|
|
5499
|
+
var import_react38 = require("react");
|
|
5500
|
+
var import_react_intl20 = require("react-intl");
|
|
5615
5501
|
var import_jsx_runtime93 = require("react/jsx-runtime");
|
|
5616
5502
|
function TokenSendList({ close }) {
|
|
5617
5503
|
const isDownMd = useDownMd();
|
|
@@ -5620,7 +5506,7 @@ function TokenSendList({ close }) {
|
|
|
5620
5506
|
list: walletAssets.mergedAssets
|
|
5621
5507
|
});
|
|
5622
5508
|
const { list } = useMatchChain();
|
|
5623
|
-
const [checked, setChecked] = (0,
|
|
5509
|
+
const [checked, setChecked] = (0, import_react38.useState)();
|
|
5624
5510
|
const modal = useModal();
|
|
5625
5511
|
const onNext = () => {
|
|
5626
5512
|
checked && modal.show((props) => {
|
|
@@ -5671,24 +5557,24 @@ function TokenSendList({ close }) {
|
|
|
5671
5557
|
index
|
|
5672
5558
|
);
|
|
5673
5559
|
}) }),
|
|
5674
|
-
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)(Button, { size: "lg", highlight: true, block: true, disabled: !checked, onClick: onNext, children: /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
5560
|
+
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)(Button, { size: "lg", highlight: true, block: true, disabled: !checked, onClick: onNext, children: /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(import_react_intl20.FormattedMessage, { id: "next" }) })
|
|
5675
5561
|
] });
|
|
5676
5562
|
}
|
|
5677
5563
|
|
|
5678
5564
|
// src/components/TransactionList/index.tsx
|
|
5679
5565
|
var import_react_infinite_scroll_component = __toESM(require("react-infinite-scroll-component"));
|
|
5680
|
-
var
|
|
5566
|
+
var import_react39 = require("react");
|
|
5681
5567
|
var import_viem12 = require("viem");
|
|
5682
5568
|
var import_viem13 = require("viem");
|
|
5683
|
-
var
|
|
5569
|
+
var import_react_intl21 = require("react-intl");
|
|
5684
5570
|
var import_jsx_runtime94 = require("react/jsx-runtime");
|
|
5685
5571
|
var Item = ({ data }) => {
|
|
5686
5572
|
const { address } = useWallet();
|
|
5687
5573
|
const isOut = data.from.toLowerCase() == address.toLowerCase();
|
|
5688
5574
|
const { chain, chainId, explorerLink, formatUnits: chainFormatUnits } = useMatchChain();
|
|
5689
5575
|
const { contracts } = useContractStore_default();
|
|
5690
|
-
const [shouldRefetch, setShouldRefetch] = (0,
|
|
5691
|
-
const transferType = (0,
|
|
5576
|
+
const [shouldRefetch, setShouldRefetch] = (0, import_react39.useState)(true);
|
|
5577
|
+
const transferType = (0, import_react39.useMemo)(() => {
|
|
5692
5578
|
const methodId = data.input.substring(2, 10);
|
|
5693
5579
|
if (methodId == "095ea7b3") {
|
|
5694
5580
|
return "erc20_approve";
|
|
@@ -5698,7 +5584,7 @@ var Item = ({ data }) => {
|
|
|
5698
5584
|
}
|
|
5699
5585
|
return "unknown";
|
|
5700
5586
|
}, [data.input]);
|
|
5701
|
-
const to = (0,
|
|
5587
|
+
const to = (0, import_react39.useMemo)(() => {
|
|
5702
5588
|
if (!isOut) {
|
|
5703
5589
|
return data.from;
|
|
5704
5590
|
}
|
|
@@ -5711,7 +5597,7 @@ var Item = ({ data }) => {
|
|
|
5711
5597
|
}
|
|
5712
5598
|
return data.to;
|
|
5713
5599
|
}, [data.input, transferType, data.to, isOut]);
|
|
5714
|
-
const amount = (0,
|
|
5600
|
+
const amount = (0, import_react39.useMemo)(() => {
|
|
5715
5601
|
if (transferType == "erc20_transfer") {
|
|
5716
5602
|
const decodeData = (0, import_viem12.decodeFunctionData)({
|
|
5717
5603
|
abi: import_viem13.erc20Abi,
|
|
@@ -5729,7 +5615,7 @@ var Item = ({ data }) => {
|
|
|
5729
5615
|
refetchInterval: shouldRefetch ? 3e3 : false,
|
|
5730
5616
|
enabled: shouldRefetch && data.source == "local"
|
|
5731
5617
|
});
|
|
5732
|
-
const status = (0,
|
|
5618
|
+
const status = (0, import_react39.useMemo)(() => {
|
|
5733
5619
|
if (data.source == "matchain") {
|
|
5734
5620
|
switch (data.extra.status) {
|
|
5735
5621
|
case "ok":
|
|
@@ -5756,12 +5642,12 @@ var Item = ({ data }) => {
|
|
|
5756
5642
|
}
|
|
5757
5643
|
return "loading";
|
|
5758
5644
|
}, [data.extra?.status, data.source, hashQuery.data]);
|
|
5759
|
-
(0,
|
|
5645
|
+
(0, import_react39.useEffect)(() => {
|
|
5760
5646
|
if (data.hash) {
|
|
5761
5647
|
setShouldRefetch(status == "loading");
|
|
5762
5648
|
}
|
|
5763
5649
|
}, [status, data.hash]);
|
|
5764
|
-
const symbol = (0,
|
|
5650
|
+
const symbol = (0, import_react39.useMemo)(() => {
|
|
5765
5651
|
if (transferType == "erc20_transfer") {
|
|
5766
5652
|
const contract = contracts[`${chainId}-${data.to.toLowerCase()}`];
|
|
5767
5653
|
return contract?.symbol || contract?.name || "unknown";
|
|
@@ -5813,7 +5699,7 @@ function TransactionList({
|
|
|
5813
5699
|
/* @__PURE__ */ (0, import_jsx_runtime94.jsx)(LoadingIcon_default, { rotate: true, size: 16, color: "black" }),
|
|
5814
5700
|
"Loading..."
|
|
5815
5701
|
] }),
|
|
5816
|
-
endMessage: items.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: `matchid-list-nomore`, children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
|
|
5702
|
+
endMessage: items.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: `matchid-list-nomore`, children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "noMoreRecords" }) }) : /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: `matchid-list-nomore`, children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_intl21.FormattedMessage, { id: "noRecords" }) }),
|
|
5817
5703
|
children: items.length == 0 && !hasMore ? /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: "mt-[150px]" }) : /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: `matchid-transaction-list`, children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(Item, { data: item }, index)) })
|
|
5818
5704
|
}
|
|
5819
5705
|
);
|
|
@@ -5833,7 +5719,6 @@ function TransactionList({
|
|
|
5833
5719
|
ModalWithHeader,
|
|
5834
5720
|
Overlay,
|
|
5835
5721
|
Popover,
|
|
5836
|
-
SOLModal,
|
|
5837
5722
|
TONModal,
|
|
5838
5723
|
TRONModal,
|
|
5839
5724
|
TokenDetail,
|