@gardenfi/orderbook 0.2.0-beta.30 → 0.2.0-beta.32

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/index3.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var i=(e=>(e.Bitcoin="Bitcoin",e.EVM="EVM",e))(i||{}),o=(e=>(e.mainnet="mainnet",e.testnet="testnet",e.localnet="localnet",e))(o||{});const t={bitcoin:"bitcoin",bitcoin_testnet:"bitcoin_testnet",bitcoin_regtest:"bitcoin_regtest",ethereum:"ethereum",base:"base",ethereum_arbitrum:"ethereum_arbitrum",ethereum_sepolia:"ethereum_sepolia",arbitrum_localnet:"arbitrum_localnet",arbitrum_sepolia:"arbitrum_sepolia",ethereum_localnet:"ethereum_localnet",base_sepolia:"base_sepolia",bera_testnet:"bera_testnet"},a=e=>!(e===t.ethereum_sepolia||e===t.bitcoin_testnet||e===t.bitcoin_regtest||e===t.arbitrum_localnet||e===t.ethereum_localnet||e===t.arbitrum_sepolia||e===t.base_sepolia||e===t.bera_testnet),s=e=>e===t.bitcoin||e===t.bitcoin_testnet||e===t.bitcoin_regtest,n=e=>e===t.ethereum||e===t.ethereum_arbitrum||e===t.ethereum_sepolia||e===t.ethereum_localnet||e===t.arbitrum_localnet||e===t.arbitrum_sepolia||e===t.base_sepolia||e===t.base||e===t.bera_testnet,r={[t.bitcoin]:288,[t.bitcoin_testnet]:288,[t.bitcoin_regtest]:288,[t.ethereum]:14400,[t.ethereum_arbitrum]:14400,[t.ethereum_sepolia]:14400,[t.arbitrum_localnet]:14400,[t.arbitrum_sepolia]:14400,[t.ethereum_localnet]:14400,[t.base_sepolia]:14400,[t.base]:86400,[t.bera_testnet]:0},u=e=>{if(s(e))return"Bitcoin";if(n(e))return"EVM";throw new Error("Invalid or unsupported chain")},l=e=>{if(!r[e])throw new Error("Invalid or unsupported chain");return r[e]};exports.BlockchainType=i;exports.Chains=t;exports.NetworkType=o;exports.TimeLocks=r;exports.getBlockchainType=u;exports.getTimeLock=l;exports.isBitcoin=s;exports.isEVM=n;exports.isMainnet=a;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var i=(e=>(e.Bitcoin="Bitcoin",e.EVM="EVM",e))(i||{}),o=(e=>(e.mainnet="mainnet",e.testnet="testnet",e.localnet="localnet",e))(o||{});const t={bitcoin:"bitcoin",bitcoin_testnet:"bitcoin_testnet",bitcoin_regtest:"bitcoin_regtest",ethereum:"ethereum",base:"base",ethereum_arbitrum:"ethereum_arbitrum",ethereum_sepolia:"ethereum_sepolia",arbitrum_localnet:"arbitrum_localnet",arbitrum_sepolia:"arbitrum_sepolia",ethereum_localnet:"ethereum_localnet",base_sepolia:"base_sepolia",bera_testnet:"bera_testnet"},a=e=>!(e===t.ethereum_sepolia||e===t.bitcoin_testnet||e===t.bitcoin_regtest||e===t.arbitrum_localnet||e===t.ethereum_localnet||e===t.arbitrum_sepolia||e===t.base_sepolia||e===t.bera_testnet),s=e=>e===t.bitcoin||e===t.bitcoin_testnet||e===t.bitcoin_regtest,n=e=>e===t.ethereum||e===t.ethereum_arbitrum||e===t.ethereum_sepolia||e===t.ethereum_localnet||e===t.arbitrum_localnet||e===t.arbitrum_sepolia||e===t.base_sepolia||e===t.base||e===t.bera_testnet,r={[t.bitcoin]:288,[t.bitcoin_testnet]:288,[t.bitcoin_regtest]:288,[t.ethereum]:14400,[t.ethereum_arbitrum]:14400,[t.ethereum_sepolia]:14400,[t.arbitrum_localnet]:14400,[t.arbitrum_sepolia]:14400,[t.ethereum_localnet]:14400,[t.base_sepolia]:14400,[t.base]:86400,[t.bera_testnet]:57600},l=e=>{if(s(e))return"Bitcoin";if(n(e))return"EVM";throw new Error("Invalid or unsupported chain")},u=e=>{if(console.log("TimeLocks[chain] :",e,r[e]),!r[e])throw new Error("Invalid or unsupported chain");return r[e]};exports.BlockchainType=i;exports.Chains=t;exports.NetworkType=o;exports.TimeLocks=r;exports.getBlockchainType=l;exports.getTimeLock=u;exports.isBitcoin=s;exports.isEVM=n;exports.isMainnet=a;
package/dist/index3.js CHANGED
@@ -1,4 +1,4 @@
1
- var i = /* @__PURE__ */ ((e) => (e.Bitcoin = "Bitcoin", e.EVM = "EVM", e))(i || {}), o = /* @__PURE__ */ ((e) => (e.mainnet = "mainnet", e.testnet = "testnet", e.localnet = "localnet", e))(o || {});
1
+ var o = /* @__PURE__ */ ((e) => (e.Bitcoin = "Bitcoin", e.EVM = "EVM", e))(o || {}), i = /* @__PURE__ */ ((e) => (e.mainnet = "mainnet", e.testnet = "testnet", e.localnet = "localnet", e))(i || {});
2
2
  const t = {
3
3
  bitcoin: "bitcoin",
4
4
  bitcoin_testnet: "bitcoin_testnet",
@@ -24,19 +24,19 @@ const t = {
24
24
  [t.ethereum_localnet]: 14400,
25
25
  [t.base_sepolia]: 14400,
26
26
  [t.base]: 86400,
27
- [t.bera_testnet]: 0
27
+ [t.bera_testnet]: 57600
28
28
  }, u = (e) => {
29
29
  if (s(e)) return "Bitcoin";
30
30
  if (n(e)) return "EVM";
31
31
  throw new Error("Invalid or unsupported chain");
32
32
  }, _ = (e) => {
33
- if (!r[e]) throw new Error("Invalid or unsupported chain");
33
+ if (console.log("TimeLocks[chain] :", e, r[e]), !r[e]) throw new Error("Invalid or unsupported chain");
34
34
  return r[e];
35
35
  };
36
36
  export {
37
- i as BlockchainType,
37
+ o as BlockchainType,
38
38
  t as Chains,
39
- o as NetworkType,
39
+ i as NetworkType,
40
40
  r as TimeLocks,
41
41
  u as getBlockchainType,
42
42
  _ as getTimeLock,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gardenfi/orderbook",
3
- "version": "0.2.0-beta.30",
3
+ "version": "0.2.0-beta.32",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",