@ape.swap/bonds-sdk 1.0.222 → 1.0.224
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/components/Bonds/Bonds.js +10 -10
- package/dist/scss/Bonds.scss +13 -3
- package/package.json +1 -1
|
@@ -188,16 +188,16 @@ var Bonds = function (_a) {
|
|
|
188
188
|
};
|
|
189
189
|
return (_jsxs(ThemeUIProvider, __assign({ theme: defaultTheme }, { children: [isActive && account && _jsx("p", { children: account }), isActive && account && _jsx("button", __assign({ onClick: handleApprove }, { children: "Approve USDT" })), _jsxs(Flex, __assign({ className: "container table-container" }, { children: [_jsxs(Flex, __assign({ className: "container header-container" }, { children: [_jsx(Flex, __assign({ className: "column column-token" }, { children: "Tokens" })), _jsx(Flex, { className: "column column-tokeninfo" }), _jsx(Flex, __assign({ className: "column column-discount" }, { children: _jsxs(TooltipBubble, __assign({ body: _jsx(Flex, { children: TooltipText.Discount }), width: "230px", placement: "bottomLeft", transformTip: "translate(18%, -4%)" }, { children: ["Discount", _jsx(Flex, __assign({ className: "column header-icon" }, { children: _jsx(Svg, { icon: "questionCircle", width: "12px" }) }))] })) })), _jsx(Flex, __assign({ className: "column column-arr" }, { children: _jsxs(TooltipBubble, __assign({ body: _jsx(Flex, { children: TooltipText.ARR }), width: "230px", placement: "bottomLeft", transformTip: "translate(8%, -5%)" }, { children: ["ARR", _jsx(Flex, __assign({ className: "column header-icon" }, { children: _jsx(Svg, { icon: "questionCircle", width: "12px" }) }))] })) })), _jsx(Flex, __assign({ className: "column column-term" }, { children: _jsxs(TooltipBubble, __assign({ body: _jsx(Flex, { children: TooltipText.Terms }), width: "230px", placement: "bottomRight", transformTip: "translate(11%, -5%)" }, { children: ["Terms", _jsx(Flex, __assign({ className: "column header-icon" }, { children: _jsx(Svg, { icon: "questionCircle", width: "12px" }) }))] })) })), _jsx(Flex, __assign({ className: "column column-tokensremaining" }, { children: _jsxs(TooltipBubble, __assign({ body: _jsx(Flex, { children: TooltipText.TokensRemaining }), width: "230px", placement: "bottomRight", transformTip: "translate(12%, -4%)" }, { children: ["Tokens Remaining", _jsx(Flex, __assign({ className: "column header-icon" }, { children: _jsx(Svg, { icon: "questionCircle", width: "12px" }) }))] })) })), _jsx(Flex, { className: "column column-hotbond" })] })), sortedBonds.map(function (bond) {
|
|
190
190
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
191
|
-
return (_jsxs(Flex, __assign({ className: "container bondrow-container", onClick: function () { return rowClick(bond); } }, { children: [_jsx(Flex, __assign({ className: "column column-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
191
|
+
return (_jsxs(Flex, __assign({ className: "container bondrow-container", onClick: function () { return rowClick(bond); } }, { children: [_jsxs(Flex, __assign({ className: "column column-tokens" }, { children: [_jsx(Flex, __assign({ className: "column column-tokenname" }, { children: bond.showcaseTokenName })), _jsxs(Flex, __assign({ className: "column column-tokenicons" }, { children: [_jsx(TooltipBubble, __assign({ body: _jsx(Tooltip, { tokenContract: (bond === null || bond === void 0 ? void 0 : bond.payoutToken) || '', secondURL: getBillContractURL(bond), secondURLTitle: 'View Bond Contract', thirdURL: "https://dashboard.ape.bond/bond/".concat((_a = bond === null || bond === void 0 ? void 0 : bond.billAddress) === null || _a === void 0 ? void 0 : _a.toLowerCase()), thirdURLTitle: 'View Insights', twitter: bond === null || bond === void 0 ? void 0 : bond.twitter, projectLink: bond === null || bond === void 0 ? void 0 : bond.projectLink, audit: bond === null || bond === void 0 ? void 0 : bond.audit, chain: (_b = bond.chainId) !== null && _b !== void 0 ? _b : ChainId.BSC }), width: "205px", placement: "bottomRight", transformTip: "translate(11%, 0%)" }, { children: _jsx(Svg, { icon: "infoSolid", width: "12px" }) })), _jsx(Svg, { icon: "expand", width: "15px", color: "white2" }), _jsx(ListTag, { text: (_c = bond === null || bond === void 0 ? void 0 : bond.tags) === null || _c === void 0 ? void 0 : _c[0], variant: ((_d = bond === null || bond === void 0 ? void 0 : bond.tags) === null || _d === void 0 ? void 0 : _d[0]) === 'Cex Fund' ? 'cex_fund' : 'liquidity' })] }))] })), _jsxs(Flex, __assign({ className: "column column-bondinfo" }, { children: [_jsx(Flex, __assign({ className: "column column-discount ".concat(getDiscountColor(bond === null || bond === void 0 ? void 0 : bond.discount)) }, { children: "".concat((_e = bond === null || bond === void 0 ? void 0 : bond.discount) === null || _e === void 0 ? void 0 : _e.toFixed(2), "%") })), _jsx(Flex, __assign({ className: "column column-arr" }, { children: "".concat(((((_f = bond === null || bond === void 0 ? void 0 : bond.discount) !== null && _f !== void 0 ? _f : 0) * 365) / vestingTime(bond.vestingTerm).days).toFixed(2), "%") })), _jsx(Flex, __assign({ className: "column column-term" }, { children: vestingTime(bond.vestingTerm).days ? "".concat(vestingTime(bond.vestingTerm).days, " D") : '-' })), _jsx(Flex, __assign({ className: "column column-tokensremaining" }, { children: _jsx(ProgressBarWrapper, { title: '', value: _jsx(ProgressBar, { value: remainingPercentage(bond) }), style: {
|
|
192
|
+
width: '127px',
|
|
193
|
+
height: '25px',
|
|
194
|
+
flexDirection: 'column',
|
|
195
|
+
justifyContent: 'center',
|
|
196
|
+
display: ['none', 'none', 'none', 'flex'],
|
|
197
|
+
}, showTooltip: true, toolTip: "".concat(remainingTokensFormat(bond), " ").concat(bond.payoutTokenName, " (").concat(formatDollar({
|
|
198
|
+
num: remainingTokensUsd(bond).toNumber(),
|
|
199
|
+
isPrice: true,
|
|
200
|
+
}), ")") }) })), _jsx(Flex, __assign({ className: "column column-hotbond" }, { children: _jsx(Flex, __assign({ className: "column column-icon" }, { children: hotBonds.includes(bond.billAddress.toLowerCase()) && ((_g = bond.discount) !== null && _g !== void 0 ? _g : 0) > 0 && (_jsx(Svg, { icon: "hot", width: "20px" })) })) }))] }))] }), bond.billAddress));
|
|
201
201
|
})] }))] })));
|
|
202
202
|
};
|
|
203
203
|
export default Bonds;
|
package/dist/scss/Bonds.scss
CHANGED
|
@@ -42,25 +42,35 @@
|
|
|
42
42
|
justify-content: center;
|
|
43
43
|
align-items: center;
|
|
44
44
|
flex: 1;
|
|
45
|
-
min-width: 150px;
|
|
46
45
|
text-align: center;
|
|
47
46
|
cursor: pointer;
|
|
48
47
|
}
|
|
49
48
|
|
|
49
|
+
.column.column-tokens {
|
|
50
|
+
display: flex;
|
|
51
|
+
align-items: center;
|
|
52
|
+
width: 50%;
|
|
53
|
+
}
|
|
54
|
+
|
|
50
55
|
.column.column-token {
|
|
51
|
-
min-width: 100px;
|
|
52
56
|
flex-direction: row;
|
|
53
57
|
justify-content: start;
|
|
54
58
|
align-items: center;
|
|
55
59
|
padding-left: 20px;
|
|
56
60
|
}
|
|
57
61
|
|
|
58
|
-
.column.column-
|
|
62
|
+
.column.column-tokenicons {
|
|
59
63
|
flex-direction: row;
|
|
60
64
|
align-items: center;
|
|
61
65
|
justify-content: space-evenly;
|
|
62
66
|
}
|
|
63
67
|
|
|
68
|
+
.column.column-bondinfo {
|
|
69
|
+
flex-direction: row;
|
|
70
|
+
align-items: center;
|
|
71
|
+
width: 50%;
|
|
72
|
+
}
|
|
73
|
+
|
|
64
74
|
.column.column-discount {
|
|
65
75
|
flex-direction: column;
|
|
66
76
|
justify-content: center;
|