anymal-protocol 1.0.39 → 1.0.40

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/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- declare function useVerifyAccount(): (pid: string, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
1
+ declare function useVerifyAccount(): (pid: string, isCampaign: boolean, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
2
2
  success: boolean;
3
3
  message: string;
4
4
  }>;
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- declare function useVerifyAccount(): (pid: string, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
1
+ declare function useVerifyAccount(): (pid: string, isCampaign: boolean, dbAuthToken: string, bundlerClient: any, smartAccount: any, accountRewardsContractAddress: `0x${string}`) => Promise<{
2
2
  success: boolean;
3
3
  message: string;
4
4
  }>;
package/dist/index.js CHANGED
@@ -70,7 +70,7 @@ var MARKETPLACE_ABI = [{ "inputs": [{ "internalType": "address", "name": "target
70
70
  // src/utils/account/useVerifyAccount.ts
71
71
  function useVerifyAccount() {
72
72
  return (0, import_react.useCallback)(
73
- async (pid, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
73
+ async (pid, isCampaign, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
74
74
  if (!dbAuthToken || !bundlerClient || !smartAccount || !accountRewardsContractAddress || !pid) {
75
75
  return {
76
76
  success: false,
@@ -80,7 +80,7 @@ function useVerifyAccount() {
80
80
  const callData = (0, import_viem.encodeFunctionData)({
81
81
  abi: VERIFY_ACCOUNT_ABI,
82
82
  functionName: "claimRewardByName",
83
- args: ["petastic-signup-campaign-1", pid]
83
+ args: [isCampaign ? "petastic-signup-campaign-1" : "default", pid]
84
84
  });
85
85
  try {
86
86
  const userOpHash = await bundlerClient.sendUserOperation({
@@ -92,7 +92,6 @@ function useVerifyAccount() {
92
92
  }
93
93
  ],
94
94
  maxPriorityFeePerGas: (0, import_viem.parseGwei)("0.001")
95
- // maxFeePerGas: parseGwei("5.599"),
96
95
  });
97
96
  await bundlerClient.waitForUserOperationReceipt({
98
97
  hash: userOpHash,
@@ -469,7 +468,6 @@ function useMintAnymalNFT() {
469
468
  }
470
469
  ],
471
470
  maxPriorityFeePerGas: (0, import_viem2.parseGwei)("0.001")
472
- // maxFeePerGas: parseGwei("5.599"),
473
471
  });
474
472
  await bundlerClient.waitForUserOperationReceipt({
475
473
  hash: userOpHash,
package/dist/index.mjs CHANGED
@@ -25,7 +25,7 @@ var MARKETPLACE_ABI = [{ "inputs": [{ "internalType": "address", "name": "target
25
25
  // src/utils/account/useVerifyAccount.ts
26
26
  function useVerifyAccount() {
27
27
  return useCallback(
28
- async (pid, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
28
+ async (pid, isCampaign, dbAuthToken, bundlerClient, smartAccount, accountRewardsContractAddress) => {
29
29
  if (!dbAuthToken || !bundlerClient || !smartAccount || !accountRewardsContractAddress || !pid) {
30
30
  return {
31
31
  success: false,
@@ -35,7 +35,7 @@ function useVerifyAccount() {
35
35
  const callData = encodeFunctionData({
36
36
  abi: VERIFY_ACCOUNT_ABI,
37
37
  functionName: "claimRewardByName",
38
- args: ["petastic-signup-campaign-1", pid]
38
+ args: [isCampaign ? "petastic-signup-campaign-1" : "default", pid]
39
39
  });
40
40
  try {
41
41
  const userOpHash = await bundlerClient.sendUserOperation({
@@ -47,7 +47,6 @@ function useVerifyAccount() {
47
47
  }
48
48
  ],
49
49
  maxPriorityFeePerGas: parseGwei("0.001")
50
- // maxFeePerGas: parseGwei("5.599"),
51
50
  });
52
51
  await bundlerClient.waitForUserOperationReceipt({
53
52
  hash: userOpHash,
@@ -424,7 +423,6 @@ function useMintAnymalNFT() {
424
423
  }
425
424
  ],
426
425
  maxPriorityFeePerGas: parseGwei2("0.001")
427
- // maxFeePerGas: parseGwei("5.599"),
428
426
  });
429
427
  await bundlerClient.waitForUserOperationReceipt({
430
428
  hash: userOpHash,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "anymal-protocol",
3
- "version": "1.0.39",
3
+ "version": "1.0.40",
4
4
  "description": "A React/TypeScript-based utility library for reusable functions and hooks inside of the Anymal Ecosystem.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",