@ape.swap/bonds-sdk 1.0.353 → 1.0.355
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.
|
@@ -204,16 +204,16 @@ var YourBonds = function (_a) {
|
|
|
204
204
|
});
|
|
205
205
|
return __assign(__assign({}, data), { userOwnedBills: enrichedUserBills });
|
|
206
206
|
});
|
|
207
|
-
console.log("userBillNftData");
|
|
208
|
-
console.log(
|
|
209
|
-
console.log("userBillNftData");
|
|
210
|
-
console.log("userOwnedBillsData");
|
|
211
|
-
console.log(
|
|
212
|
-
console.log("userOwnedBillsData");
|
|
207
|
+
// console.log("userBillNftData");
|
|
208
|
+
// console.log(userBillNftData);
|
|
209
|
+
// console.log("userBillNftData");
|
|
210
|
+
// console.log("userOwnedBillsData");
|
|
211
|
+
// console.log(userOwnedBillsData);
|
|
212
|
+
// console.log("userOwnedBillsData");
|
|
213
213
|
console.log("combinedData");
|
|
214
214
|
console.log(combinedData);
|
|
215
215
|
console.log("combinedData");
|
|
216
|
-
return [2 /*return*/, Promise.resolve(
|
|
216
|
+
return [2 /*return*/, Promise.resolve(combinedData)];
|
|
217
217
|
case 3:
|
|
218
218
|
error_2 = _a.sent();
|
|
219
219
|
console.error('Error fetching user owned bills data:', error_2);
|
|
@@ -344,6 +344,9 @@ var YourBonds = function (_a) {
|
|
|
344
344
|
fontWeight: 600,
|
|
345
345
|
width: '100%',
|
|
346
346
|
} }, { children: "Claim All" })) }))] }))] })), userOwnedBillsData.flat().map(function (data) {
|
|
347
|
+
console.log("ROWDATA");
|
|
348
|
+
console.log(data);
|
|
349
|
+
console.log("ROWDATA");
|
|
347
350
|
var sortedBills = data.userOwnedBills.sort(function (a, b) {
|
|
348
351
|
var claimableDifference = claimable(b) - claimable(a);
|
|
349
352
|
if (claimableDifference !== 0) {
|
|
@@ -351,10 +354,9 @@ var YourBonds = function (_a) {
|
|
|
351
354
|
}
|
|
352
355
|
return totalPending(b) - totalPending(a);
|
|
353
356
|
});
|
|
354
|
-
console.log(sortedBills);
|
|
355
357
|
return sortedBills.map(function (bill) {
|
|
356
|
-
var _a, _b;
|
|
357
|
-
return (_jsxs(Flex, __assign({ className: "container bondrow-container", onClick: function () { return rowClick(bill.bond); } }, { children: [_jsx(Flex, __assign({ className: "column column-tokens" }, { children:
|
|
358
|
+
var _a, _b, _c;
|
|
359
|
+
return (_jsxs(Flex, __assign({ className: "container bondrow-container", onClick: function () { return rowClick(bill.bond); } }, { children: [_jsx(Flex, __assign({ className: "column column-tokens" }, { children: _jsxs(Flex, __assign({ className: "column column-tokeninfoname" }, { children: [_jsx(TokenInfoAndName, { bill: bill.bond, vestEnds: "Ends in ".concat(getPendingVesting(bill.lastBlockTimestamp, bill.vesting)) }), (_a = bill.nftData) === null || _a === void 0 ? void 0 : _a.image] })) })), _jsxs(Flex, __assign({ className: "column column-bondinfo" }, { children: [_jsxs(Flex, __assign({ className: "column column-claimable" }, { children: [formatNumberSI(parseFloat(claimable(bill).toFixed(3)), 0), "($".concat((claimable(bill) * ((_b = parseFloat(earnTokenPrice(bill.bond))) !== null && _b !== void 0 ? _b : 0)).toFixed(2), ")")] })), _jsxs(Flex, __assign({ className: "column column-pending" }, { children: [formatNumberSI(parseFloat(totalPending(bill).toFixed(0)), 0), "($".concat((totalPending(bill) * ((_c = parseFloat(earnTokenPrice(bill.bond))) !== null && _c !== void 0 ? _c : 0)).toFixed(2), ")")] })), _jsx(Flex, __assign({ className: "column column-term" }, { children: "".concat(vestingTimeRemaining(bill).days, "d, ").concat(vestingTimeRemaining(bill).hours, "h, ").concat(vestingTimeRemaining(bill).minutes, "m") })), _jsx(Flex, __assign({ className: "column column-claimall" }, { children: _jsx(Flex, __assign({ className: "column-claimall button" }, { children: _jsx(Button, __assign({ disabled: !account, sx: {
|
|
358
360
|
height: ['36px', '36px', '36px', '26px'],
|
|
359
361
|
lineHeight: '12px',
|
|
360
362
|
fontSize: '14px',
|