@aztec/constants 4.0.0-nightly.20250907 → 4.0.0-nightly.20260108
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/dest/constants.d.ts +9 -1
- package/dest/constants.d.ts.map +1 -1
- package/dest/constants.gen.d.ts +279 -312
- package/dest/constants.gen.d.ts.map +1 -1
- package/dest/constants.gen.js +278 -311
- package/dest/constants.js +14 -0
- package/dest/scripts/constants.in.d.ts +1 -1
- package/dest/scripts/constants.in.js +36 -16
- package/package.json +5 -3
- package/src/constants.gen.ts +294 -319
- package/src/constants.ts +26 -0
package/src/constants.ts
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
|
+
import { BlockNumber, CheckpointNumber } from '@aztec/foundation/branded-types';
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
|
+
|
|
4
|
+
// Re-export L2 block number constants with proper BlockNumber type
|
|
5
|
+
// Note: The generated constants are plain numbers, but we provide typed versions here
|
|
6
|
+
import {
|
|
7
|
+
GENESIS_BLOCK_HEADER_HASH as GENESIS_BLOCK_HEADER_HASH_BIGINT,
|
|
8
|
+
INITIAL_CHECKPOINT_NUMBER as INITIAL_CHECKPOINT_NUM_RAW,
|
|
9
|
+
INITIAL_L2_BLOCK_NUM as INITIAL_L2_BLOCK_NUM_RAW,
|
|
10
|
+
} from './constants.gen.js';
|
|
11
|
+
|
|
1
12
|
// Typescript-land-only constants
|
|
2
13
|
export const SPONSORED_FPC_SALT = BigInt(0);
|
|
3
14
|
|
|
4
15
|
// Autogenerated constants loaded from noir-land
|
|
16
|
+
// eslint-disable-next-line import/export
|
|
5
17
|
export * from './constants.gen.js';
|
|
18
|
+
|
|
19
|
+
/** The initial L2 block number (typed as BlockNumber). This is the first block number in the Aztec L2 chain. */
|
|
20
|
+
// Shadow the export from constants.gen above
|
|
21
|
+
// eslint-disable-next-line import/export
|
|
22
|
+
export const INITIAL_L2_BLOCK_NUM: BlockNumber = BlockNumber(INITIAL_L2_BLOCK_NUM_RAW);
|
|
23
|
+
|
|
24
|
+
/** The initial L2 checkpoint number (typed as CheckpointNumber). This is the first checkpoint number in the Aztec L2 chain. */
|
|
25
|
+
// Shadow the export from constants.gen above
|
|
26
|
+
export const INITIAL_L2_CHECKPOINT_NUM: CheckpointNumber = CheckpointNumber(INITIAL_CHECKPOINT_NUM_RAW);
|
|
27
|
+
|
|
28
|
+
/** The block header hash for the genesis block 0. */
|
|
29
|
+
// Shadow the export from constants.gen above
|
|
30
|
+
// eslint-disable-next-line import/export
|
|
31
|
+
export const GENESIS_BLOCK_HEADER_HASH = new Fr(GENESIS_BLOCK_HEADER_HASH_BIGINT);
|