timelock-sdk 0.0.50 → 0.0.51

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/abis.cjs CHANGED
@@ -1,4 +1,4 @@
1
- const require_optionsMarket = require('./optionsMarket-PBduSBXF.cjs');
1
+ const require_optionsMarket = require('./optionsMarket-DEFMUI2G.cjs');
2
2
  const require_singleOwnerVault = require('./singleOwnerVault-gf2zNZVk.cjs');
3
3
 
4
4
  exports.erc20Abi = require_optionsMarket.erc20Abi;
package/dist/abis.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { n as optionsMarketAbi, r as lensAbi, t as uniswapMathLensAbi } from "./uniswapMathLens-BiaRFVeY.cjs";
1
+ import { n as optionsMarketAbi, r as lensAbi, t as uniswapMathLensAbi } from "./uniswapMathLens-BQ_ArpKd.cjs";
2
2
 
3
3
  //#region src/abis/erc20.d.ts
4
4
  declare const erc20Abi: readonly [{
package/dist/abis.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { n as optionsMarketAbi, r as lensAbi, t as uniswapMathLensAbi } from "./uniswapMathLens-uDGUc-kg.js";
1
+ import { n as optionsMarketAbi, r as lensAbi, t as uniswapMathLensAbi } from "./uniswapMathLens-DCuaXAGZ.js";
2
2
 
3
3
  //#region src/abis/erc20.d.ts
4
4
  declare const erc20Abi: readonly [{
package/dist/abis.js CHANGED
@@ -1,4 +1,4 @@
1
- import { i as erc20Abi, n as uniswapMathLensAbi, r as lensAbi, t as optionsMarketAbi } from "./optionsMarket-CvArD6d_.js";
1
+ import { i as erc20Abi, n as uniswapMathLensAbi, r as lensAbi, t as optionsMarketAbi } from "./optionsMarket-BDBU1gUS.js";
2
2
  import { n as uniswapV3PoolAbi, t as singleOwnerVaultAbi } from "./singleOwnerVault-BeJChjfJ.js";
3
3
 
4
4
  export { erc20Abi, lensAbi, optionsMarketAbi, singleOwnerVaultAbi, uniswapMathLensAbi, uniswapV3PoolAbi };
package/dist/client.cjs CHANGED
@@ -1,8 +1,8 @@
1
1
  'use client';
2
2
 
3
3
 
4
- const require_numberUtils = require('./numberUtils-BKQtAolx.cjs');
5
- const require_optionsMarket = require('./optionsMarket-PBduSBXF.cjs');
4
+ const require_numberUtils = require('./numberUtils-CkwkoxOr.cjs');
5
+ const require_optionsMarket = require('./optionsMarket-DEFMUI2G.cjs');
6
6
  const require_singleOwnerVault = require('./singleOwnerVault-gf2zNZVk.cjs');
7
7
  let viem = require("viem");
8
8
  viem = require_numberUtils.__toESM(viem);
@@ -355,7 +355,10 @@ const useMintOption = (marketAddr) => {
355
355
  };
356
356
  const mintOption = async (optionType, amount, duration, strikeTick) => {
357
357
  if (!client) throw new Error("Wallet not connected");
358
- if (!timelockLens || !vault || !marketAddr || !currentTick || !tickSpacing) throw new Error("Lowest tick lower not available");
358
+ if (!marketAddr) throw new Error("Market address not available");
359
+ if (!timelockLens) throw new Error("Timelock lens not available");
360
+ if (!vault) throw new Error("Vault not available");
361
+ if (currentTick === void 0 || !tickSpacing) throw new Error("Pool data not available");
359
362
  strikeTick = require_numberUtils.roundTickDown(strikeTick ?? currentTick, tickSpacing);
360
363
  if (optionType === "CALL" && optionAssetIsToken0 || optionType === "PUT" && !optionAssetIsToken0) strikeTick += tickSpacing;
361
364
  const [premium, protocolFee] = await require_numberUtils.getTimelockMarket(marketAddr, client).read.calculatePremium([