@hinkal/common 0.1.17 → 0.1.19

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.
Files changed (48) hide show
  1. package/addGlobals.cjs +1 -0
  2. package/addGlobals.d.ts +1 -0
  3. package/addGlobals.mjs +9 -0
  4. package/crypto/preProcessing.cjs +1 -1
  5. package/crypto/preProcessing.mjs +7 -9
  6. package/data-structures/Hinkal/Hinkal.cjs +1 -1
  7. package/data-structures/Hinkal/Hinkal.mjs +2 -4
  8. package/data-structures/Hinkal/hinkalPrivateWallet.cjs +1 -1
  9. package/data-structures/Hinkal/hinkalPrivateWallet.mjs +2 -4
  10. package/data-structures/event-service/AbstractAccessTokenSnapshotService.cjs +1 -1
  11. package/data-structures/event-service/AbstractAccessTokenSnapshotService.mjs +2 -4
  12. package/data-structures/event-service/AbstractCommitmentsSnapshotService.cjs +1 -1
  13. package/data-structures/event-service/AbstractCommitmentsSnapshotService.mjs +10 -12
  14. package/data-structures/snapshot/ClientAccessTokenSnapshotService.cjs +1 -1
  15. package/data-structures/snapshot/ClientAccessTokenSnapshotService.mjs +8 -10
  16. package/data-structures/snapshot/ClientCommitmentsSnapshotService.cjs +1 -1
  17. package/data-structures/snapshot/ClientCommitmentsSnapshotService.mjs +8 -10
  18. package/data-structures/snapshot/ClientNullifierSnapshotService.cjs +1 -1
  19. package/data-structures/snapshot/ClientNullifierSnapshotService.mjs +2 -4
  20. package/functions/pre-transaction/outputUtxoProcessing.cjs +1 -1
  21. package/functions/pre-transaction/outputUtxoProcessing.mjs +4 -6
  22. package/functions/pre-transaction/processAmountChanges.cjs +1 -1
  23. package/functions/pre-transaction/processAmountChanges.mjs +9 -11
  24. package/functions/protocols/pendle.helpers.cjs +1 -1
  25. package/functions/protocols/pendle.helpers.mjs +10 -12
  26. package/functions/staking/index.cjs +1 -1
  27. package/functions/staking/index.mjs +21 -23
  28. package/functions/web3/odosAPI.cjs +1 -1
  29. package/functions/web3/odosAPI.mjs +8 -10
  30. package/functions/web3/oneInchAPI.cjs +1 -1
  31. package/functions/web3/oneInchAPI.mjs +6 -8
  32. package/functions/web3/runContractFunction.cjs +1 -1
  33. package/functions/web3/runContractFunction.mjs +18 -20
  34. package/functions/web3/uniswapAPI.cjs +1 -1
  35. package/functions/web3/uniswapAPI.mjs +2 -4
  36. package/index.cjs +1 -1
  37. package/index.mjs +639 -638
  38. package/package.json +1 -1
  39. package/providers/prepareEthersHinkal.cjs +1 -1
  40. package/providers/prepareEthersHinkal.mjs +24 -7
  41. package/providers/prepareWagmiv1Hinkal.cjs +1 -1
  42. package/providers/prepareWagmiv1Hinkal.mjs +27 -10
  43. package/webworker/utxoWorker/utxoWorkerLauncher.cjs +1 -1
  44. package/webworker/utxoWorker/utxoWorkerLauncher.mjs +1 -1
  45. package/webworker/zkProofWorker/zkProofWorkerLauncher.cjs +1 -1
  46. package/webworker/zkProofWorker/zkProofWorkerLauncher.mjs +1 -1
  47. package/data-structures/index.cjs +0 -1
  48. package/data-structures/index.mjs +0 -26
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hinkal/common",
3
- "version": "0.1.17",
3
+ "version": "0.1.19",
4
4
  "homepage": "hinkal.pro",
5
5
  "author": {
6
6
  "name": "Hinkal Protocol"
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../data-structures/index.cjs");require("circomlibjs");require("ethers");const t=require("../crypto/preProcessing.cjs"),r=require("./EthersProviderAdapter.cjs"),a=require("../data-structures/Hinkal/Hinkal.cjs"),n=async i=>{await t.preProcessing();const e=new a.Hinkal;return r.ethersProvierAdapter.initSigner?.(i),await e.initProviderAdapter(void 0,r.ethersProvierAdapter),await e.initUserKeys(),await e.resetMerkle(),e};exports.prepareEthersHinkal=n;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("ethers");require("circomlibjs");require("libsodium-wrappers");const t=require("../data-structures/Hinkal/Hinkal.cjs");require("../constants/chains.constants.cjs");require("../types/circom-data.types.cjs");require("../types/transactions.types.cjs");require("../types/curve.types.cjs");require("../data-structures/custom-token-registry/CustomTokenRegistry.cjs");require("../constants/vite.constants.cjs");require("axios");require("../constants/coingecko.constants.cjs");require("../constants/contracts.constants.cjs");require("../constants/kyc.constants.cjs");require("../constants/axelar.constants.cjs");require("../constants/rewards.constants.cjs");require("../constants/reorg-depths.constants.cjs");const u=require("../crypto/preProcessing.cjs");require("../functions/utils/external-action.utils.cjs");require("../functions/web3/events/getShieldedBalance.cjs");require("../data-structures/volatile-helper/VolatileHelper.cjs");require("idb-keyval");const r=require("./EthersProviderAdapter.cjs"),q=async i=>{await u.preProcessing();const e=new t.Hinkal;return r.ethersProvierAdapter.initSigner?.(i),await e.initProviderAdapter(void 0,r.ethersProvierAdapter),await e.initUserKeys(),await e.resetMerkle(),e};exports.prepareEthersHinkal=q;
@@ -1,14 +1,31 @@
1
- import "../data-structures/index.mjs";
2
- import "circomlibjs";
3
1
  import "ethers";
4
- import { preProcessing as e } from "../crypto/preProcessing.mjs";
5
- import { ethersProvierAdapter as i } from "./EthersProviderAdapter.mjs";
2
+ import "circomlibjs";
3
+ import "libsodium-wrappers";
6
4
  import { Hinkal as o } from "../data-structures/Hinkal/Hinkal.mjs";
7
- const c = async (t) => {
8
- await e();
5
+ import "../constants/chains.constants.mjs";
6
+ import "../types/circom-data.types.mjs";
7
+ import "../types/transactions.types.mjs";
8
+ import "../types/curve.types.mjs";
9
+ import "../data-structures/custom-token-registry/CustomTokenRegistry.mjs";
10
+ import "../constants/vite.constants.mjs";
11
+ import "axios";
12
+ import "../constants/coingecko.constants.mjs";
13
+ import "../constants/contracts.constants.mjs";
14
+ import "../constants/kyc.constants.mjs";
15
+ import "../constants/axelar.constants.mjs";
16
+ import "../constants/rewards.constants.mjs";
17
+ import "../constants/reorg-depths.constants.mjs";
18
+ import { preProcessing as p } from "../crypto/preProcessing.mjs";
19
+ import "../functions/utils/external-action.utils.mjs";
20
+ import "../functions/web3/events/getShieldedBalance.mjs";
21
+ import "../data-structures/volatile-helper/VolatileHelper.mjs";
22
+ import "idb-keyval";
23
+ import { ethersProvierAdapter as i } from "./EthersProviderAdapter.mjs";
24
+ const S = async (t) => {
25
+ await p();
9
26
  const r = new o();
10
27
  return i.initSigner?.(t), await r.initProviderAdapter(void 0, i), await r.initUserKeys(), await r.resetMerkle(), r;
11
28
  };
12
29
  export {
13
- c as prepareEthersHinkal
30
+ S as prepareEthersHinkal
14
31
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../data-structures/index.cjs");require("circomlibjs");require("ethers");const i=require("../crypto/preProcessing.cjs"),a=require("./Wagmiv1ProviderAdapter.cjs"),t=require("../data-structures/Hinkal/Hinkal.cjs"),n=async r=>{await i.preProcessing();const e=new t.Hinkal;return await e.initProviderAdapter(r,a.wagmiv1ProvierAdapter),await e.initUserKeys(),await e.resetMerkle(),e};exports.prepareWagmiv1Hinkal=n;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("ethers");require("circomlibjs");require("libsodium-wrappers");const i=require("../data-structures/Hinkal/Hinkal.cjs");require("../constants/chains.constants.cjs");require("../types/circom-data.types.cjs");require("../types/transactions.types.cjs");require("../types/curve.types.cjs");require("../data-structures/custom-token-registry/CustomTokenRegistry.cjs");require("../constants/vite.constants.cjs");require("axios");require("../constants/coingecko.constants.cjs");require("../constants/contracts.constants.cjs");require("../constants/kyc.constants.cjs");require("../constants/axelar.constants.cjs");require("../constants/rewards.constants.cjs");require("../constants/reorg-depths.constants.cjs");const u=require("../crypto/preProcessing.cjs");require("../functions/utils/external-action.utils.cjs");require("../functions/web3/events/getShieldedBalance.cjs");require("../data-structures/volatile-helper/VolatileHelper.cjs");require("idb-keyval");const a=require("./Wagmiv1ProviderAdapter.cjs"),q=async r=>{await u.preProcessing();const e=new i.Hinkal;return await e.initProviderAdapter(r,a.wagmiv1ProvierAdapter),await e.initUserKeys(),await e.resetMerkle(),e};exports.prepareWagmiv1Hinkal=q;
@@ -1,14 +1,31 @@
1
- import "../data-structures/index.mjs";
2
- import "circomlibjs";
3
1
  import "ethers";
4
- import { preProcessing as t } from "../crypto/preProcessing.mjs";
5
- import { wagmiv1ProvierAdapter as a } from "./Wagmiv1ProviderAdapter.mjs";
6
- import { Hinkal as e } from "../data-structures/Hinkal/Hinkal.mjs";
7
- const c = async (i) => {
8
- await t();
9
- const r = new e();
10
- return await r.initProviderAdapter(i, a), await r.initUserKeys(), await r.resetMerkle(), r;
2
+ import "circomlibjs";
3
+ import "libsodium-wrappers";
4
+ import { Hinkal as t } from "../data-structures/Hinkal/Hinkal.mjs";
5
+ import "../constants/chains.constants.mjs";
6
+ import "../types/circom-data.types.mjs";
7
+ import "../types/transactions.types.mjs";
8
+ import "../types/curve.types.mjs";
9
+ import "../data-structures/custom-token-registry/CustomTokenRegistry.mjs";
10
+ import "../constants/vite.constants.mjs";
11
+ import "axios";
12
+ import "../constants/coingecko.constants.mjs";
13
+ import "../constants/contracts.constants.mjs";
14
+ import "../constants/kyc.constants.mjs";
15
+ import "../constants/axelar.constants.mjs";
16
+ import "../constants/rewards.constants.mjs";
17
+ import "../constants/reorg-depths.constants.mjs";
18
+ import { preProcessing as o } from "../crypto/preProcessing.mjs";
19
+ import "../functions/utils/external-action.utils.mjs";
20
+ import "../functions/web3/events/getShieldedBalance.mjs";
21
+ import "../data-structures/volatile-helper/VolatileHelper.mjs";
22
+ import "idb-keyval";
23
+ import { wagmiv1ProvierAdapter as p } from "./Wagmiv1ProviderAdapter.mjs";
24
+ const W = async (i) => {
25
+ await o();
26
+ const r = new t();
27
+ return await r.initProviderAdapter(i, p), await r.initUserKeys(), await r.resetMerkle(), r;
11
28
  };
12
29
  export {
13
- c as prepareWagmiv1Hinkal
30
+ W as prepareWagmiv1Hinkal
14
31
  };
@@ -1 +1 @@
1
- "use strict";const e=""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/../../assets/utxoWorkerLauncher-CB4QU7Zm.js").href:new URL("../../assets/utxoWorkerLauncher-CB4QU7Zm.js",document.currentScript&&document.currentScript.src||document.baseURI).href);module.exports=e;
1
+ "use strict";const e=""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/../../assets/utxoWorkerLauncher-CDsBG9Fd.js").href:new URL("../../assets/utxoWorkerLauncher-CDsBG9Fd.js",document.currentScript&&document.currentScript.src||document.baseURI).href);module.exports=e;
@@ -1,4 +1,4 @@
1
- const e = "" + new URL("../../assets/utxoWorkerLauncher-CB4QU7Zm.js", import.meta.url).href;
1
+ const e = "" + new URL("../../assets/utxoWorkerLauncher-CDsBG9Fd.js", import.meta.url).href;
2
2
  export {
3
3
  e as default
4
4
  };
@@ -1 +1 @@
1
- "use strict";const r=""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/../../assets/zkProofWorkerLauncher-CqRz9ir5.js").href:new URL("../../assets/zkProofWorkerLauncher-CqRz9ir5.js",document.currentScript&&document.currentScript.src||document.baseURI).href);module.exports=r;
1
+ "use strict";const e=""+(typeof document>"u"?require("url").pathToFileURL(__dirname+"/../../assets/zkProofWorkerLauncher-D9WIis_4.js").href:new URL("../../assets/zkProofWorkerLauncher-D9WIis_4.js",document.currentScript&&document.currentScript.src||document.baseURI).href);module.exports=e;
@@ -1,4 +1,4 @@
1
- const r = "" + new URL("../../assets/zkProofWorkerLauncher-CqRz9ir5.js", import.meta.url).href;
1
+ const r = "" + new URL("../../assets/zkProofWorkerLauncher-D9WIis_4.js", import.meta.url).href;
2
2
  export {
3
3
  r as default
4
4
  };
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("circomlibjs");require("ethers");const e=require("../crypto/preProcessing.cjs");require("libsodium-wrappers");require("../constants/chains.constants.cjs");require("../types/circom-data.types.cjs");require("../types/transactions.types.cjs");require("../types/curve.types.cjs");require("../functions/web3/events/getShieldedBalance.cjs");const r=require("./custom-token-registry/CustomTokenRegistry.cjs");require("../constants/vite.constants.cjs");require("axios");require("../constants/coingecko.constants.cjs");require("../constants/contracts.constants.cjs");require("../constants/kyc.constants.cjs");require("../constants/axelar.constants.cjs");require("../constants/rewards.constants.cjs");require("../constants/reorg-depths.constants.cjs");require("../functions/utils/external-action.utils.cjs");const i=require("./volatile-helper/VolatileHelper.cjs");require("idb-keyval");e.preProcessing();exports.customTokenRegistry=r.customTokenRegistry;exports.VolatileHelper=i.VolatileHelper;
@@ -1,26 +0,0 @@
1
- import "circomlibjs";
2
- import "ethers";
3
- import { preProcessing as o } from "../crypto/preProcessing.mjs";
4
- import "libsodium-wrappers";
5
- import "../constants/chains.constants.mjs";
6
- import "../types/circom-data.types.mjs";
7
- import "../types/transactions.types.mjs";
8
- import "../types/curve.types.mjs";
9
- import "../functions/web3/events/getShieldedBalance.mjs";
10
- import { customTokenRegistry as V } from "./custom-token-registry/CustomTokenRegistry.mjs";
11
- import "../constants/vite.constants.mjs";
12
- import "axios";
13
- import "../constants/coingecko.constants.mjs";
14
- import "../constants/contracts.constants.mjs";
15
- import "../constants/kyc.constants.mjs";
16
- import "../constants/axelar.constants.mjs";
17
- import "../constants/rewards.constants.mjs";
18
- import "../constants/reorg-depths.constants.mjs";
19
- import "../functions/utils/external-action.utils.mjs";
20
- import { VolatileHelper as d } from "./volatile-helper/VolatileHelper.mjs";
21
- import "idb-keyval";
22
- o();
23
- export {
24
- d as VolatileHelper,
25
- V as customTokenRegistry
26
- };