@semaphore-protocol/group 4.0.0-beta.10 → 4.0.0-beta.11
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.cjs +3 -3
- package/dist/index.js +2 -2
- package/dist/types/index.d.ts +1 -1
- package/package.json +3 -3
- package/src/index.ts +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @module @semaphore-protocol/group
|
|
3
|
-
* @version 4.0.0-beta.
|
|
3
|
+
* @version 4.0.0-beta.11
|
|
4
4
|
* @file A library to create and manage Semaphore groups.
|
|
5
5
|
* @copyright Ethereum Foundation 2024
|
|
6
6
|
* @license MIT
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
'use strict';
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var leanImt = require('@zk-kit/lean-imt');
|
|
12
12
|
|
|
13
13
|
function getDefaultExportFromCjs (x) {
|
|
14
14
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
@@ -134,7 +134,7 @@ class Group {
|
|
|
134
134
|
throw new Error("Failed to add member: value cannot be 0");
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
|
-
this.leanIMT = new
|
|
137
|
+
this.leanIMT = new leanImt.LeanIMT((a, b) => poseidon2_2([a, b]), members.map(BigInt));
|
|
138
138
|
}
|
|
139
139
|
/**
|
|
140
140
|
* Returns the root hash of the tree.
|
package/dist/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @module @semaphore-protocol/group
|
|
3
|
-
* @version 4.0.0-beta.
|
|
3
|
+
* @version 4.0.0-beta.11
|
|
4
4
|
* @file A library to create and manage Semaphore groups.
|
|
5
5
|
* @copyright Ethereum Foundation 2024
|
|
6
6
|
* @license MIT
|
|
7
7
|
* @see [Github]{@link https://github.com/semaphore-protocol/semaphore/tree/main/packages/group}
|
|
8
8
|
*/
|
|
9
|
-
import { LeanIMT } from '@zk-kit/imt';
|
|
9
|
+
import { LeanIMT } from '@zk-kit/lean-imt';
|
|
10
10
|
|
|
11
11
|
function getDefaultExportFromCjs (x) {
|
|
12
12
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LeanIMT, LeanIMTMerkleProof } from "@zk-kit/imt";
|
|
1
|
+
import { LeanIMT, LeanIMTMerkleProof } from "@zk-kit/lean-imt";
|
|
2
2
|
import type { BigNumber } from "@zk-kit/utils";
|
|
3
3
|
/**
|
|
4
4
|
* The Semaphore group is a {@link https://zkkit.pse.dev/classes/_zk_kit_imt.LeanIMT.html | LeanIMT}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@semaphore-protocol/group",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.11",
|
|
4
4
|
"description": "A library to create and manage Semaphore groups.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"rollup-plugin-cleanup": "^3.2.1"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@zk-kit/imt": "2.0.
|
|
43
|
-
"@zk-kit/utils": "1.0.0
|
|
42
|
+
"@zk-kit/lean-imt": "2.0.1",
|
|
43
|
+
"@zk-kit/utils": "1.0.0"
|
|
44
44
|
}
|
|
45
45
|
}
|
package/src/index.ts
CHANGED