@ape.swap/bonds-sdk 1.0.276 → 1.0.279

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.
@@ -167,7 +167,7 @@ var BondModal = function (_a) {
167
167
  return __generator(this, function (_a) {
168
168
  switch (_a.label) {
169
169
  case 0:
170
- console.log('handle buy clicked');
170
+ console.log('handle buy clicked!');
171
171
  if (!window.ethereum) {
172
172
  console.error('No Ethereum provider found');
173
173
  alert('No Ethereum provider found');
@@ -181,6 +181,11 @@ var BondModal = function (_a) {
181
181
  _a.trys.push([1, 4, , 5]);
182
182
  maxPrice = new BigNumber(bondData[0].trueBillPrice).times(102).div(100);
183
183
  amount = adjustDecimals(inputValue);
184
+ console.log('-------');
185
+ console.log(amount);
186
+ console.log(maxPrice);
187
+ console.log(bondData[0].trueBillPrice);
188
+ console.log('-------');
184
189
  return [4 /*yield*/, bondContract.deposit(amount, maxPrice, account)];
185
190
  case 2:
186
191
  tx = _a.sent();
@@ -214,7 +219,7 @@ var BondModal = function (_a) {
214
219
  !!v.currentTarget.value && isNumber(v.currentTarget.value) && parseFloat(v.currentTarget.value) >= 0
215
220
  ? v.currentTarget.value
216
221
  : v.currentTarget.value.slice(0, v.currentTarget.value.length - 1);
217
- } }) })), _jsx(Flex, __assign({ className: "input-container token" }, { children: bond === null || bond === void 0 ? void 0 : bond.principalTokenName }))] })), _jsxs(Flex, __assign({ className: "modal-container button-container" }, { children: [_jsx(Flex, __assign({ className: "button-container get" }, { children: _jsxs(Button, { children: ["Get ", bond === null || bond === void 0 ? void 0 : bond.principalTokenName] }) })), _jsx(Flex, __assign({ className: "button-container buy" }, { children: _jsxs(Button, __assign({ onClick: function () { return handleBuy(bond); } }, { children: ["Buy ", bond === null || bond === void 0 ? void 0 : bond.showcaseTokenName] })) }))] }))] }))] })) })) }, bond.billAddress));
222
+ } }) })), _jsx(Flex, __assign({ className: "input-container token" }, { children: bond === null || bond === void 0 ? void 0 : bond.principalTokenName }))] })), _jsxs(Flex, __assign({ className: "modal-container button-container" }, { children: [_jsx(Flex, __assign({ className: "button-container get" }, { children: _jsxs(Button, { children: ["Get ", bond === null || bond === void 0 ? void 0 : bond.principalTokenName] }) })), _jsx(Flex, __assign({ className: "button-container buy" }, { children: _jsxs(Button, __assign({ onClick: function () { return handleBuy(bond); } }, { children: ["Buy: ", bond === null || bond === void 0 ? void 0 : bond.showcaseTokenName] })) }))] }))] }))] })) })) }, bond.billAddress));
218
223
  }) })));
219
224
  };
220
225
  export default BondModal;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Ape Bond SDK",
4
4
  "author": "Ape Bond",
5
5
  "license": "MIT",
6
- "version": "1.0.276",
6
+ "version": "1.0.279",
7
7
  "main": "dist/index.js",
8
8
  "module": "dist/index.es.js",
9
9
  "types": "dist/index.d.ts",
File without changes
File without changes
File without changes