@latticexyz/common 2.2.22-fdb727e847024560315c10ebf32c1f924755ffe9 → 2.2.22
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/chains.d.ts +21 -317
- package/dist/chains.js +17 -54
- package/dist/chains.js.map +1 -1
- package/dist/{chunk-NFWCLD5I.js → chunk-ETXWXV5T.js} +14 -1
- package/dist/chunk-ETXWXV5T.js.map +1 -0
- package/dist/codegen.d.ts +2 -2
- package/dist/codegen.js +9 -5
- package/dist/codegen.js.map +1 -1
- package/dist/internal.d.ts +11 -1
- package/dist/internal.js +387 -2
- package/dist/internal.js.map +1 -1
- package/dist/utils.js +2 -4
- package/package.json +3 -3
- package/dist/chunk-CHXZROA7.js +0 -16
- package/dist/chunk-CHXZROA7.js.map +0 -1
- package/dist/chunk-NFWCLD5I.js.map +0 -1
package/dist/chains.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as viem_chains from 'viem/chains';
|
|
2
2
|
import { Chain } from 'viem/chains';
|
|
3
3
|
import * as viem from 'viem';
|
|
4
|
-
import * as viem_experimental from 'viem/experimental';
|
|
5
4
|
import * as viem_op_stack from 'viem/op-stack';
|
|
6
5
|
|
|
7
6
|
type MUDChain = Chain & {
|
|
@@ -36,6 +35,7 @@ declare const mudFoundry: {
|
|
|
36
35
|
multicall3?: viem.ChainContract | undefined;
|
|
37
36
|
universalSignatureVerifier?: viem.ChainContract | undefined;
|
|
38
37
|
} | undefined;
|
|
38
|
+
readonly ensTlds?: readonly string[] | undefined;
|
|
39
39
|
readonly id: 31337;
|
|
40
40
|
readonly name: "Foundry";
|
|
41
41
|
readonly nativeCurrency: {
|
|
@@ -106,6 +106,7 @@ declare const redstone: {
|
|
|
106
106
|
readonly address: "0x4200000000000000000000000000000000000016";
|
|
107
107
|
};
|
|
108
108
|
};
|
|
109
|
+
readonly ensTlds?: readonly string[] | undefined;
|
|
109
110
|
readonly id: 690;
|
|
110
111
|
readonly name: "Redstone";
|
|
111
112
|
readonly nativeCurrency: {
|
|
@@ -312,7 +313,7 @@ declare const redstone: {
|
|
|
312
313
|
value: bigint;
|
|
313
314
|
yParity: number;
|
|
314
315
|
accessList: viem.AccessList;
|
|
315
|
-
authorizationList:
|
|
316
|
+
authorizationList: viem.SignedAuthorizationList<number>;
|
|
316
317
|
blobVersionedHashes?: undefined;
|
|
317
318
|
chainId: number;
|
|
318
319
|
type: "eip7702";
|
|
@@ -370,15 +371,10 @@ declare const garnet: {
|
|
|
370
371
|
readonly webSocket: readonly ["wss://rpc.garnetchain.com"];
|
|
371
372
|
};
|
|
372
373
|
};
|
|
373
|
-
readonly iconUrls: readonly ["https://redstone.xyz/chain-icons/garnet.png"];
|
|
374
|
-
readonly indexerUrl: "https://indexer.mud.garnetchain.com";
|
|
375
|
-
readonly blockExplorers: {
|
|
376
|
-
readonly default: {
|
|
377
|
-
readonly name: "Blockscout";
|
|
378
|
-
readonly url: "https://explorer.garnetchain.com";
|
|
379
|
-
};
|
|
380
|
-
};
|
|
381
374
|
readonly contracts: {
|
|
375
|
+
readonly quarryPaymaster: {
|
|
376
|
+
readonly address: "0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f";
|
|
377
|
+
};
|
|
382
378
|
readonly multicall3: {
|
|
383
379
|
readonly address: "0xca11bde05977b3631167028862be2a173976ca11";
|
|
384
380
|
};
|
|
@@ -419,6 +415,15 @@ declare const garnet: {
|
|
|
419
415
|
readonly address: "0x4200000000000000000000000000000000000016";
|
|
420
416
|
};
|
|
421
417
|
};
|
|
418
|
+
readonly iconUrls: readonly ["https://redstone.xyz/chain-icons/garnet.png"];
|
|
419
|
+
readonly indexerUrl: "https://indexer.mud.garnetchain.com";
|
|
420
|
+
readonly blockExplorers: {
|
|
421
|
+
readonly default: {
|
|
422
|
+
readonly name: "Blockscout";
|
|
423
|
+
readonly url: "https://explorer.garnetchain.com";
|
|
424
|
+
};
|
|
425
|
+
};
|
|
426
|
+
readonly ensTlds?: readonly string[] | undefined;
|
|
422
427
|
readonly id: 17069;
|
|
423
428
|
readonly name: "Garnet Testnet";
|
|
424
429
|
readonly nativeCurrency: {
|
|
@@ -619,7 +624,7 @@ declare const garnet: {
|
|
|
619
624
|
value: bigint;
|
|
620
625
|
yParity: number;
|
|
621
626
|
accessList: viem.AccessList;
|
|
622
|
-
authorizationList:
|
|
627
|
+
authorizationList: viem.SignedAuthorizationList<number>;
|
|
623
628
|
blobVersionedHashes?: undefined;
|
|
624
629
|
chainId: number;
|
|
625
630
|
type: "eip7702";
|
|
@@ -666,310 +671,6 @@ declare const garnet: {
|
|
|
666
671
|
};
|
|
667
672
|
};
|
|
668
673
|
|
|
669
|
-
declare const rhodolite: {
|
|
670
|
-
readonly name: "Rhodolite Devnet";
|
|
671
|
-
readonly testnet: true;
|
|
672
|
-
readonly id: 17420;
|
|
673
|
-
readonly sourceId: 17000;
|
|
674
|
-
readonly nativeCurrency: {
|
|
675
|
-
readonly name: "Ether";
|
|
676
|
-
readonly symbol: "ETH";
|
|
677
|
-
readonly decimals: 18;
|
|
678
|
-
};
|
|
679
|
-
readonly rpcUrls: {
|
|
680
|
-
readonly default: {
|
|
681
|
-
readonly http: readonly ["https://rpc.rhodolitechain.com"];
|
|
682
|
-
readonly webSocket: readonly ["wss://rpc.rhodolitechain.com"];
|
|
683
|
-
};
|
|
684
|
-
readonly bundler: {
|
|
685
|
-
readonly http: readonly ["https://rpc.rhodolitechain.com"];
|
|
686
|
-
readonly webSocket: readonly ["wss://rpc.rhodolitechain.com"];
|
|
687
|
-
};
|
|
688
|
-
readonly quarryPassIssuer: {
|
|
689
|
-
readonly http: readonly ["https://rpc.rhodolitechain.com"];
|
|
690
|
-
readonly webSocket: readonly ["wss://rpc.rhodolitechain.com"];
|
|
691
|
-
};
|
|
692
|
-
readonly wiresaw: {
|
|
693
|
-
readonly http: readonly ["https://rpc.rhodolitechain.com"];
|
|
694
|
-
readonly webSocket: readonly ["wss://rpc.rhodolitechain.com"];
|
|
695
|
-
};
|
|
696
|
-
};
|
|
697
|
-
readonly contracts: {
|
|
698
|
-
readonly l1StandardBridge: {
|
|
699
|
-
readonly 17000: {
|
|
700
|
-
readonly address: "0x6487446e0B9FAEa90F6a9772A6448cFa780E30F9";
|
|
701
|
-
};
|
|
702
|
-
};
|
|
703
|
-
readonly quarryPaymaster: {
|
|
704
|
-
readonly address: "0x7ca1b85aca23fccf2fbac14c02b5e8a6432639b9";
|
|
705
|
-
};
|
|
706
|
-
readonly gasPriceOracle: {
|
|
707
|
-
readonly address: "0x420000000000000000000000000000000000000F";
|
|
708
|
-
};
|
|
709
|
-
readonly l1Block: {
|
|
710
|
-
readonly address: "0x4200000000000000000000000000000000000015";
|
|
711
|
-
};
|
|
712
|
-
readonly l2CrossDomainMessenger: {
|
|
713
|
-
readonly address: "0x4200000000000000000000000000000000000007";
|
|
714
|
-
};
|
|
715
|
-
readonly l2Erc721Bridge: {
|
|
716
|
-
readonly address: "0x4200000000000000000000000000000000000014";
|
|
717
|
-
};
|
|
718
|
-
readonly l2StandardBridge: {
|
|
719
|
-
readonly address: "0x4200000000000000000000000000000000000010";
|
|
720
|
-
};
|
|
721
|
-
readonly l2ToL1MessagePasser: {
|
|
722
|
-
readonly address: "0x4200000000000000000000000000000000000016";
|
|
723
|
-
};
|
|
724
|
-
};
|
|
725
|
-
readonly blockExplorers: {
|
|
726
|
-
readonly default: {
|
|
727
|
-
readonly name: "Blockscout";
|
|
728
|
-
readonly url: "https://explorer.rhodolitechain.com";
|
|
729
|
-
};
|
|
730
|
-
readonly worldsExplorer: {
|
|
731
|
-
readonly name: "MUD Worlds Explorer";
|
|
732
|
-
readonly url: "https://explorer.mud.dev/rhodolite/worlds";
|
|
733
|
-
};
|
|
734
|
-
};
|
|
735
|
-
readonly iconUrls: readonly ["https://redstone.xyz/chain-icons/rhodolite.png"];
|
|
736
|
-
readonly indexerUrl: "https://indexer.mud.rhodolitechain.com";
|
|
737
|
-
readonly formatters: {
|
|
738
|
-
readonly block: {
|
|
739
|
-
exclude: [] | undefined;
|
|
740
|
-
format: (args: viem_op_stack.OpStackRpcBlock<viem.BlockTag, boolean>) => {
|
|
741
|
-
baseFeePerGas: bigint | null;
|
|
742
|
-
blobGasUsed: bigint;
|
|
743
|
-
difficulty: bigint;
|
|
744
|
-
excessBlobGas: bigint;
|
|
745
|
-
extraData: `0x${string}`;
|
|
746
|
-
gasLimit: bigint;
|
|
747
|
-
gasUsed: bigint;
|
|
748
|
-
hash: `0x${string}` | null;
|
|
749
|
-
logsBloom: `0x${string}` | null;
|
|
750
|
-
miner: `0x${string}`;
|
|
751
|
-
mixHash: `0x${string}`;
|
|
752
|
-
nonce: `0x${string}` | null;
|
|
753
|
-
number: bigint | null;
|
|
754
|
-
parentBeaconBlockRoot?: `0x${string}` | undefined;
|
|
755
|
-
parentHash: `0x${string}`;
|
|
756
|
-
receiptsRoot: `0x${string}`;
|
|
757
|
-
sealFields: `0x${string}`[];
|
|
758
|
-
sha3Uncles: `0x${string}`;
|
|
759
|
-
size: bigint;
|
|
760
|
-
stateRoot: `0x${string}`;
|
|
761
|
-
timestamp: bigint;
|
|
762
|
-
totalDifficulty: bigint | null;
|
|
763
|
-
transactions: `0x${string}`[] | viem_op_stack.OpStackTransaction<boolean>[];
|
|
764
|
-
transactionsRoot: `0x${string}`;
|
|
765
|
-
uncles: `0x${string}`[];
|
|
766
|
-
withdrawals?: viem.Withdrawal[] | undefined;
|
|
767
|
-
withdrawalsRoot?: `0x${string}` | undefined;
|
|
768
|
-
};
|
|
769
|
-
type: "block";
|
|
770
|
-
};
|
|
771
|
-
readonly transaction: {
|
|
772
|
-
exclude: [] | undefined;
|
|
773
|
-
format: (args: viem_op_stack.OpStackRpcTransaction<boolean>) => {
|
|
774
|
-
blockHash: `0x${string}` | null;
|
|
775
|
-
blockNumber: bigint | null;
|
|
776
|
-
from: `0x${string}`;
|
|
777
|
-
gas: bigint;
|
|
778
|
-
hash: `0x${string}`;
|
|
779
|
-
input: `0x${string}`;
|
|
780
|
-
nonce: number;
|
|
781
|
-
r: `0x${string}`;
|
|
782
|
-
s: `0x${string}`;
|
|
783
|
-
to: `0x${string}` | null;
|
|
784
|
-
transactionIndex: number | null;
|
|
785
|
-
typeHex: `0x${string}` | null;
|
|
786
|
-
v: bigint;
|
|
787
|
-
value: bigint;
|
|
788
|
-
yParity: number;
|
|
789
|
-
gasPrice?: undefined;
|
|
790
|
-
maxFeePerBlobGas?: undefined;
|
|
791
|
-
maxFeePerGas: bigint;
|
|
792
|
-
maxPriorityFeePerGas: bigint;
|
|
793
|
-
isSystemTx?: boolean | undefined;
|
|
794
|
-
mint?: bigint | undefined;
|
|
795
|
-
sourceHash: `0x${string}`;
|
|
796
|
-
type: "deposit";
|
|
797
|
-
} | {
|
|
798
|
-
r: `0x${string}`;
|
|
799
|
-
s: `0x${string}`;
|
|
800
|
-
v: bigint;
|
|
801
|
-
to: `0x${string}` | null;
|
|
802
|
-
from: `0x${string}`;
|
|
803
|
-
gas: bigint;
|
|
804
|
-
nonce: number;
|
|
805
|
-
value: bigint;
|
|
806
|
-
blockHash: `0x${string}` | null;
|
|
807
|
-
blockNumber: bigint | null;
|
|
808
|
-
hash: `0x${string}`;
|
|
809
|
-
input: `0x${string}`;
|
|
810
|
-
transactionIndex: number | null;
|
|
811
|
-
typeHex: `0x${string}` | null;
|
|
812
|
-
accessList?: undefined;
|
|
813
|
-
authorizationList?: undefined;
|
|
814
|
-
blobVersionedHashes?: undefined;
|
|
815
|
-
chainId?: number | undefined;
|
|
816
|
-
yParity?: undefined;
|
|
817
|
-
type: "legacy";
|
|
818
|
-
gasPrice: bigint;
|
|
819
|
-
maxFeePerBlobGas?: undefined;
|
|
820
|
-
maxFeePerGas?: undefined;
|
|
821
|
-
maxPriorityFeePerGas?: undefined;
|
|
822
|
-
isSystemTx?: undefined;
|
|
823
|
-
mint?: undefined;
|
|
824
|
-
sourceHash?: undefined;
|
|
825
|
-
} | {
|
|
826
|
-
blockHash: `0x${string}` | null;
|
|
827
|
-
blockNumber: bigint | null;
|
|
828
|
-
from: `0x${string}`;
|
|
829
|
-
gas: bigint;
|
|
830
|
-
hash: `0x${string}`;
|
|
831
|
-
input: `0x${string}`;
|
|
832
|
-
nonce: number;
|
|
833
|
-
r: `0x${string}`;
|
|
834
|
-
s: `0x${string}`;
|
|
835
|
-
to: `0x${string}` | null;
|
|
836
|
-
transactionIndex: number | null;
|
|
837
|
-
typeHex: `0x${string}` | null;
|
|
838
|
-
v: bigint;
|
|
839
|
-
value: bigint;
|
|
840
|
-
yParity: number;
|
|
841
|
-
accessList: viem.AccessList;
|
|
842
|
-
authorizationList?: undefined;
|
|
843
|
-
blobVersionedHashes?: undefined;
|
|
844
|
-
chainId: number;
|
|
845
|
-
type: "eip2930";
|
|
846
|
-
gasPrice: bigint;
|
|
847
|
-
maxFeePerBlobGas?: undefined;
|
|
848
|
-
maxFeePerGas?: undefined;
|
|
849
|
-
maxPriorityFeePerGas?: undefined;
|
|
850
|
-
isSystemTx?: undefined;
|
|
851
|
-
mint?: undefined;
|
|
852
|
-
sourceHash?: undefined;
|
|
853
|
-
} | {
|
|
854
|
-
blockHash: `0x${string}` | null;
|
|
855
|
-
blockNumber: bigint | null;
|
|
856
|
-
from: `0x${string}`;
|
|
857
|
-
gas: bigint;
|
|
858
|
-
hash: `0x${string}`;
|
|
859
|
-
input: `0x${string}`;
|
|
860
|
-
nonce: number;
|
|
861
|
-
r: `0x${string}`;
|
|
862
|
-
s: `0x${string}`;
|
|
863
|
-
to: `0x${string}` | null;
|
|
864
|
-
transactionIndex: number | null;
|
|
865
|
-
typeHex: `0x${string}` | null;
|
|
866
|
-
v: bigint;
|
|
867
|
-
value: bigint;
|
|
868
|
-
yParity: number;
|
|
869
|
-
accessList: viem.AccessList;
|
|
870
|
-
authorizationList?: undefined;
|
|
871
|
-
blobVersionedHashes?: undefined;
|
|
872
|
-
chainId: number;
|
|
873
|
-
type: "eip1559";
|
|
874
|
-
gasPrice?: undefined;
|
|
875
|
-
maxFeePerBlobGas?: undefined;
|
|
876
|
-
maxFeePerGas: bigint;
|
|
877
|
-
maxPriorityFeePerGas: bigint;
|
|
878
|
-
isSystemTx?: undefined;
|
|
879
|
-
mint?: undefined;
|
|
880
|
-
sourceHash?: undefined;
|
|
881
|
-
} | {
|
|
882
|
-
blockHash: `0x${string}` | null;
|
|
883
|
-
blockNumber: bigint | null;
|
|
884
|
-
from: `0x${string}`;
|
|
885
|
-
gas: bigint;
|
|
886
|
-
hash: `0x${string}`;
|
|
887
|
-
input: `0x${string}`;
|
|
888
|
-
nonce: number;
|
|
889
|
-
r: `0x${string}`;
|
|
890
|
-
s: `0x${string}`;
|
|
891
|
-
to: `0x${string}` | null;
|
|
892
|
-
transactionIndex: number | null;
|
|
893
|
-
typeHex: `0x${string}` | null;
|
|
894
|
-
v: bigint;
|
|
895
|
-
value: bigint;
|
|
896
|
-
yParity: number;
|
|
897
|
-
accessList: viem.AccessList;
|
|
898
|
-
authorizationList?: undefined;
|
|
899
|
-
blobVersionedHashes: readonly `0x${string}`[];
|
|
900
|
-
chainId: number;
|
|
901
|
-
type: "eip4844";
|
|
902
|
-
gasPrice?: undefined;
|
|
903
|
-
maxFeePerBlobGas: bigint;
|
|
904
|
-
maxFeePerGas: bigint;
|
|
905
|
-
maxPriorityFeePerGas: bigint;
|
|
906
|
-
isSystemTx?: undefined;
|
|
907
|
-
mint?: undefined;
|
|
908
|
-
sourceHash?: undefined;
|
|
909
|
-
} | {
|
|
910
|
-
blockHash: `0x${string}` | null;
|
|
911
|
-
blockNumber: bigint | null;
|
|
912
|
-
from: `0x${string}`;
|
|
913
|
-
gas: bigint;
|
|
914
|
-
hash: `0x${string}`;
|
|
915
|
-
input: `0x${string}`;
|
|
916
|
-
nonce: number;
|
|
917
|
-
r: `0x${string}`;
|
|
918
|
-
s: `0x${string}`;
|
|
919
|
-
to: `0x${string}` | null;
|
|
920
|
-
transactionIndex: number | null;
|
|
921
|
-
typeHex: `0x${string}` | null;
|
|
922
|
-
v: bigint;
|
|
923
|
-
value: bigint;
|
|
924
|
-
yParity: number;
|
|
925
|
-
accessList: viem.AccessList;
|
|
926
|
-
authorizationList: viem_experimental.SignedAuthorizationList<number>;
|
|
927
|
-
blobVersionedHashes?: undefined;
|
|
928
|
-
chainId: number;
|
|
929
|
-
type: "eip7702";
|
|
930
|
-
gasPrice?: undefined;
|
|
931
|
-
maxFeePerBlobGas?: undefined;
|
|
932
|
-
maxFeePerGas: bigint;
|
|
933
|
-
maxPriorityFeePerGas: bigint;
|
|
934
|
-
isSystemTx?: undefined;
|
|
935
|
-
mint?: undefined;
|
|
936
|
-
sourceHash?: undefined;
|
|
937
|
-
};
|
|
938
|
-
type: "transaction";
|
|
939
|
-
};
|
|
940
|
-
readonly transactionReceipt: {
|
|
941
|
-
exclude: [] | undefined;
|
|
942
|
-
format: (args: viem_op_stack.OpStackRpcTransactionReceipt) => {
|
|
943
|
-
blobGasPrice?: bigint | undefined;
|
|
944
|
-
blobGasUsed?: bigint | undefined;
|
|
945
|
-
blockHash: `0x${string}`;
|
|
946
|
-
blockNumber: bigint;
|
|
947
|
-
contractAddress: `0x${string}` | null | undefined;
|
|
948
|
-
cumulativeGasUsed: bigint;
|
|
949
|
-
effectiveGasPrice: bigint;
|
|
950
|
-
from: `0x${string}`;
|
|
951
|
-
gasUsed: bigint;
|
|
952
|
-
logs: viem.Log<bigint, number, false, undefined, undefined, undefined, undefined>[];
|
|
953
|
-
logsBloom: `0x${string}`;
|
|
954
|
-
root?: `0x${string}` | undefined;
|
|
955
|
-
status: "success" | "reverted";
|
|
956
|
-
to: `0x${string}` | null;
|
|
957
|
-
transactionHash: `0x${string}`;
|
|
958
|
-
transactionIndex: number;
|
|
959
|
-
type: viem.TransactionType;
|
|
960
|
-
l1GasPrice: bigint | null;
|
|
961
|
-
l1GasUsed: bigint | null;
|
|
962
|
-
l1Fee: bigint | null;
|
|
963
|
-
l1FeeScalar: number | null;
|
|
964
|
-
};
|
|
965
|
-
type: "transactionReceipt";
|
|
966
|
-
};
|
|
967
|
-
};
|
|
968
|
-
readonly serializers: {
|
|
969
|
-
readonly transaction: typeof viem_op_stack.serializeTransaction;
|
|
970
|
-
};
|
|
971
|
-
};
|
|
972
|
-
|
|
973
674
|
declare const pyrope: {
|
|
974
675
|
readonly name: "Pyrope Testnet";
|
|
975
676
|
readonly testnet: true;
|
|
@@ -996,6 +697,9 @@ declare const pyrope: {
|
|
|
996
697
|
readonly address: "0xC24932c31D9621aE9e792576152B7ef010cFC2F8";
|
|
997
698
|
};
|
|
998
699
|
};
|
|
700
|
+
readonly quarryPaymaster: {
|
|
701
|
+
readonly address: "0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f";
|
|
702
|
+
};
|
|
999
703
|
readonly gasPriceOracle: {
|
|
1000
704
|
readonly address: "0x420000000000000000000000000000000000000F";
|
|
1001
705
|
};
|
|
@@ -1216,7 +920,7 @@ declare const pyrope: {
|
|
|
1216
920
|
value: bigint;
|
|
1217
921
|
yParity: number;
|
|
1218
922
|
accessList: viem.AccessList;
|
|
1219
|
-
authorizationList:
|
|
923
|
+
authorizationList: viem.SignedAuthorizationList<number>;
|
|
1220
924
|
blobVersionedHashes?: undefined;
|
|
1221
925
|
chainId: number;
|
|
1222
926
|
type: "eip7702";
|
|
@@ -1263,4 +967,4 @@ declare const pyrope: {
|
|
|
1263
967
|
};
|
|
1264
968
|
};
|
|
1265
969
|
|
|
1266
|
-
export { type MUDChain, garnet, mudFoundry, pyrope, redstone
|
|
970
|
+
export { type MUDChain, garnet, mudFoundry, pyrope, redstone };
|
package/dist/chains.js
CHANGED
|
@@ -23,79 +23,43 @@ var garnet = {
|
|
|
23
23
|
...garnetConfig.rpcUrls,
|
|
24
24
|
bundler: garnetConfig.rpcUrls.default
|
|
25
25
|
},
|
|
26
|
-
iconUrls: ["https://redstone.xyz/chain-icons/garnet.png"],
|
|
27
|
-
indexerUrl: "https://indexer.mud.garnetchain.com"
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
// src/chains/rhodolite.ts
|
|
31
|
-
import { chainConfig } from "viem/op-stack";
|
|
32
|
-
var sourceId = 17e3;
|
|
33
|
-
var defaultRpcUrls = {
|
|
34
|
-
http: ["https://rpc.rhodolitechain.com"],
|
|
35
|
-
webSocket: ["wss://rpc.rhodolitechain.com"]
|
|
36
|
-
};
|
|
37
|
-
var rhodolite = {
|
|
38
|
-
...chainConfig,
|
|
39
|
-
name: "Rhodolite Devnet",
|
|
40
|
-
testnet: true,
|
|
41
|
-
id: 17420,
|
|
42
|
-
sourceId,
|
|
43
|
-
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
44
|
-
rpcUrls: {
|
|
45
|
-
default: defaultRpcUrls,
|
|
46
|
-
bundler: defaultRpcUrls,
|
|
47
|
-
quarryPassIssuer: defaultRpcUrls,
|
|
48
|
-
wiresaw: defaultRpcUrls
|
|
49
|
-
},
|
|
50
26
|
contracts: {
|
|
51
|
-
...
|
|
52
|
-
l1StandardBridge: {
|
|
53
|
-
[sourceId]: {
|
|
54
|
-
address: "0x6487446e0B9FAEa90F6a9772A6448cFa780E30F9"
|
|
55
|
-
}
|
|
56
|
-
},
|
|
27
|
+
...garnetConfig.contracts,
|
|
57
28
|
quarryPaymaster: {
|
|
58
|
-
address: "
|
|
29
|
+
address: "0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f"
|
|
59
30
|
}
|
|
60
31
|
},
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
name: "Blockscout",
|
|
64
|
-
url: "https://explorer.rhodolitechain.com"
|
|
65
|
-
},
|
|
66
|
-
worldsExplorer: {
|
|
67
|
-
name: "MUD Worlds Explorer",
|
|
68
|
-
url: "https://explorer.mud.dev/rhodolite/worlds"
|
|
69
|
-
}
|
|
70
|
-
},
|
|
71
|
-
iconUrls: ["https://redstone.xyz/chain-icons/rhodolite.png"],
|
|
72
|
-
indexerUrl: "https://indexer.mud.rhodolitechain.com"
|
|
32
|
+
iconUrls: ["https://redstone.xyz/chain-icons/garnet.png"],
|
|
33
|
+
indexerUrl: "https://indexer.mud.garnetchain.com"
|
|
73
34
|
};
|
|
74
35
|
|
|
75
36
|
// src/chains/pyrope.ts
|
|
76
|
-
import { chainConfig
|
|
77
|
-
var
|
|
78
|
-
var
|
|
37
|
+
import { chainConfig } from "viem/op-stack";
|
|
38
|
+
var sourceId = 11155111;
|
|
39
|
+
var defaultRpcUrls = {
|
|
79
40
|
http: ["https://rpc.pyropechain.com"],
|
|
80
41
|
webSocket: ["wss://rpc.pyropechain.com"]
|
|
81
42
|
};
|
|
82
43
|
var pyrope = {
|
|
83
|
-
...
|
|
44
|
+
...chainConfig,
|
|
84
45
|
name: "Pyrope Testnet",
|
|
85
46
|
testnet: true,
|
|
86
47
|
id: 695569,
|
|
87
|
-
sourceId
|
|
48
|
+
sourceId,
|
|
88
49
|
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
89
50
|
rpcUrls: {
|
|
90
|
-
default:
|
|
91
|
-
bundler:
|
|
51
|
+
default: defaultRpcUrls,
|
|
52
|
+
bundler: defaultRpcUrls
|
|
92
53
|
},
|
|
93
54
|
contracts: {
|
|
94
|
-
...
|
|
55
|
+
...chainConfig.contracts,
|
|
95
56
|
l1StandardBridge: {
|
|
96
|
-
[
|
|
57
|
+
[sourceId]: {
|
|
97
58
|
address: "0xC24932c31D9621aE9e792576152B7ef010cFC2F8"
|
|
98
59
|
}
|
|
60
|
+
},
|
|
61
|
+
quarryPaymaster: {
|
|
62
|
+
address: "0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f"
|
|
99
63
|
}
|
|
100
64
|
},
|
|
101
65
|
blockExplorers: {
|
|
@@ -115,7 +79,6 @@ export {
|
|
|
115
79
|
garnet,
|
|
116
80
|
mudFoundry,
|
|
117
81
|
pyrope,
|
|
118
|
-
redstone
|
|
119
|
-
rhodolite
|
|
82
|
+
redstone
|
|
120
83
|
};
|
|
121
84
|
//# sourceMappingURL=chains.js.map
|
package/dist/chains.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains/mudFoundry.ts","../src/chains/redstone.ts","../src/chains/garnet.ts","../src/chains/
|
|
1
|
+
{"version":3,"sources":["../src/chains/mudFoundry.ts","../src/chains/redstone.ts","../src/chains/garnet.ts","../src/chains/pyrope.ts"],"sourcesContent":["import { foundry } from \"viem/chains\";\nimport { MUDChain } from \"./types\";\n\nexport const mudFoundry = {\n ...foundry,\n fees: {\n defaultPriorityFee: 0n,\n },\n} as const satisfies MUDChain;\n","import { redstone as redstoneConfig } from \"viem/chains\";\nimport type { MUDChain } from \"./types\";\n\nexport const redstone = {\n ...redstoneConfig,\n iconUrls: [\"https://redstone.xyz/chain-icons/redstone.png\"],\n indexerUrl: \"https://indexer.mud.redstonechain.com\",\n} as const satisfies MUDChain;\n","import { garnet as garnetConfig } from \"viem/chains\";\nimport type { MUDChain } from \"./types\";\n\nexport const garnet = {\n ...garnetConfig,\n rpcUrls: {\n ...garnetConfig.rpcUrls,\n bundler: garnetConfig.rpcUrls.default,\n },\n contracts: {\n ...garnetConfig.contracts,\n quarryPaymaster: {\n address: \"0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f\",\n },\n },\n iconUrls: [\"https://redstone.xyz/chain-icons/garnet.png\"],\n indexerUrl: \"https://indexer.mud.garnetchain.com\",\n} as const satisfies MUDChain;\n","import { chainConfig } from \"viem/op-stack\";\nimport { MUDChain } from \"./types\";\nimport { Chain } from \"viem\";\n\nconst sourceId = 11155111;\n\nconst defaultRpcUrls = {\n http: [\"https://rpc.pyropechain.com\"],\n webSocket: [\"wss://rpc.pyropechain.com\"],\n} as const satisfies Chain[\"rpcUrls\"][\"default\"];\n\nexport const pyrope = {\n ...chainConfig,\n name: \"Pyrope Testnet\",\n testnet: true,\n id: 695569,\n sourceId,\n nativeCurrency: { name: \"Ether\", symbol: \"ETH\", decimals: 18 },\n rpcUrls: {\n default: defaultRpcUrls,\n bundler: defaultRpcUrls,\n },\n contracts: {\n ...chainConfig.contracts,\n l1StandardBridge: {\n [sourceId]: {\n address: \"0xC24932c31D9621aE9e792576152B7ef010cFC2F8\",\n },\n },\n quarryPaymaster: {\n address: \"0x2d70F1eFFbFD865764CAF19BE2A01a72F3CE774f\",\n },\n },\n blockExplorers: {\n default: {\n name: \"Blockscout\",\n url: \"https://explorer.pyropechain.com\",\n },\n worldsExplorer: {\n name: \"MUD Worlds Explorer\",\n url: \"https://explorer.mud.dev/pyrope/worlds\",\n },\n },\n iconUrls: [\"https://lattice.xyz/brand/color/pyrope.svg\"],\n indexerUrl: \"https://indexer.mud.pyropechain.com\",\n} as const satisfies MUDChain;\n"],"mappings":";AAAA,SAAS,eAAe;AAGjB,IAAM,aAAa;AAAA,EACxB,GAAG;AAAA,EACH,MAAM;AAAA,IACJ,oBAAoB;AAAA,EACtB;AACF;;;ACRA,SAAS,YAAY,sBAAsB;AAGpC,IAAM,WAAW;AAAA,EACtB,GAAG;AAAA,EACH,UAAU,CAAC,+CAA+C;AAAA,EAC1D,YAAY;AACd;;;ACPA,SAAS,UAAU,oBAAoB;AAGhC,IAAM,SAAS;AAAA,EACpB,GAAG;AAAA,EACH,SAAS;AAAA,IACP,GAAG,aAAa;AAAA,IAChB,SAAS,aAAa,QAAQ;AAAA,EAChC;AAAA,EACA,WAAW;AAAA,IACT,GAAG,aAAa;AAAA,IAChB,iBAAiB;AAAA,MACf,SAAS;AAAA,IACX;AAAA,EACF;AAAA,EACA,UAAU,CAAC,6CAA6C;AAAA,EACxD,YAAY;AACd;;;ACjBA,SAAS,mBAAmB;AAI5B,IAAM,WAAW;AAEjB,IAAM,iBAAiB;AAAA,EACrB,MAAM,CAAC,6BAA6B;AAAA,EACpC,WAAW,CAAC,2BAA2B;AACzC;AAEO,IAAM,SAAS;AAAA,EACpB,GAAG;AAAA,EACH,MAAM;AAAA,EACN,SAAS;AAAA,EACT,IAAI;AAAA,EACJ;AAAA,EACA,gBAAgB,EAAE,MAAM,SAAS,QAAQ,OAAO,UAAU,GAAG;AAAA,EAC7D,SAAS;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,WAAW;AAAA,IACT,GAAG,YAAY;AAAA,IACf,kBAAkB;AAAA,MAChB,CAAC,QAAQ,GAAG;AAAA,QACV,SAAS;AAAA,MACX;AAAA,IACF;AAAA,IACA,iBAAiB;AAAA,MACf,SAAS;AAAA,IACX;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,IACA,gBAAgB;AAAA,MACd,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,UAAU,CAAC,4CAA4C;AAAA,EACvD,YAAY;AACd;","names":[]}
|
|
@@ -82,6 +82,18 @@ function unique(values) {
|
|
|
82
82
|
return Array.from(new Set(values));
|
|
83
83
|
}
|
|
84
84
|
|
|
85
|
+
// src/utils/uniqueBy.ts
|
|
86
|
+
function uniqueBy(values, getKey) {
|
|
87
|
+
const map = /* @__PURE__ */ new Map();
|
|
88
|
+
for (const value of values) {
|
|
89
|
+
const key = getKey(value);
|
|
90
|
+
if (!map.has(key)) {
|
|
91
|
+
map.set(key, value);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
return Array.from(map.values());
|
|
95
|
+
}
|
|
96
|
+
|
|
85
97
|
// src/utils/wait.ts
|
|
86
98
|
function wait(ms) {
|
|
87
99
|
return new Promise((resolve) => setTimeout(() => resolve(), ms));
|
|
@@ -113,7 +125,8 @@ export {
|
|
|
113
125
|
iteratorToArray,
|
|
114
126
|
mapObject,
|
|
115
127
|
unique,
|
|
128
|
+
uniqueBy,
|
|
116
129
|
wait,
|
|
117
130
|
waitForIdle
|
|
118
131
|
};
|
|
119
|
-
//# sourceMappingURL=chunk-
|
|
132
|
+
//# sourceMappingURL=chunk-ETXWXV5T.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/utils/assertExhaustive.ts","../src/utils/bigIntMax.ts","../src/utils/bigIntMin.ts","../src/utils/bigIntSort.ts","../src/utils/chunk.ts","../src/utils/groupBy.ts","../src/utils/identity.ts","../src/utils/includes.ts","../src/utils/indent.ts","../src/utils/isDefined.ts","../src/utils/isNotNull.ts","../src/utils/iteratorToArray.ts","../src/utils/mapObject.ts","../src/utils/unique.ts","../src/utils/uniqueBy.ts","../src/utils/wait.ts","../src/utils/waitForIdle.ts"],"sourcesContent":["export function assertExhaustive(value: never, message?: string): never {\n throw new Error(message ?? `Unexpected value: ${value}`);\n}\n","export function bigIntMax(...args: bigint[]): bigint {\n return args.reduce((m, e) => (e > m ? e : m));\n}\n","export function bigIntMin(...args: bigint[]): bigint {\n return args.reduce((m, e) => (e < m ? e : m));\n}\n","export function bigIntSort(a: bigint, b: bigint): -1 | 0 | 1 {\n return a < b ? -1 : a > b ? 1 : 0;\n}\n","export function* chunk<T>(arr: readonly T[], n: number): Generator<readonly T[], void> {\n for (let i = 0; i < arr.length; i += n) {\n yield arr.slice(i, i + n);\n }\n}\n","export function groupBy<value, key>(\n values: readonly value[],\n getKey: (value: value) => key,\n): Map<key, readonly value[]> {\n const map = new Map<key, readonly value[]>();\n for (const value of values) {\n const key = getKey(value);\n if (!map.has(key)) map.set(key, []);\n (map.get(key) as value[]).push(value);\n }\n return map;\n}\n","export function identity<T>(value: T): T {\n return value;\n}\n","// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function includes<item>(items: item[], value: any): value is item {\n return items.includes(value);\n}\n","export function indent(message: string, indentation = \" \"): string {\n return message.replaceAll(/(^|\\n)/g, `$1${indentation}`);\n}\n","export function isDefined<T>(argument: T | undefined): argument is T {\n return argument !== undefined;\n}\n","export function isNotNull<T>(argument: T | null): argument is T {\n return argument !== null;\n}\n","export async function iteratorToArray<T>(iterator: AsyncIterable<T>): Promise<readonly T[]> {\n const items: T[] = [];\n for await (const item of iterator) {\n items.push(item);\n }\n return items;\n}\n","/**\n * Map each key of a source object via a given valueMap function\n */\nexport function mapObject<\n Source extends Record<string | number | symbol, unknown>,\n Target extends { [key in keyof Source]: unknown },\n>(source: Source, valueMap: (value: Source[typeof key], key: keyof Source) => Target[typeof key]): Target {\n return Object.fromEntries(\n Object.entries(source).map(([key, value]) => [key, valueMap(value as Source[keyof Source], key)]),\n ) as Target;\n}\n","export function unique<value>(values: readonly value[]): readonly value[] {\n return Array.from(new Set(values));\n}\n","export function uniqueBy<value, key>(values: readonly value[], getKey: (value: value) => key): readonly value[] {\n const map = new Map<key, value>();\n for (const value of values) {\n const key = getKey(value);\n if (!map.has(key)) {\n map.set(key, value);\n }\n }\n return Array.from(map.values());\n}\n","export function wait(ms: number): Promise<void> {\n return new Promise<void>((resolve) => setTimeout(() => resolve(), ms));\n}\n","export function waitForIdle(): Promise<void> {\n return new Promise<void>((resolve) => {\n if (typeof requestIdleCallback !== \"undefined\") {\n requestIdleCallback(() => resolve());\n } else {\n setTimeout(() => resolve(), 1);\n }\n });\n}\n"],"mappings":";AAAO,SAAS,iBAAiB,OAAc,SAAyB;AACtE,QAAM,IAAI,MAAM,WAAW,qBAAqB,KAAK,EAAE;AACzD;;;ACFO,SAAS,aAAa,MAAwB;AACnD,SAAO,KAAK,OAAO,CAAC,GAAG,MAAO,IAAI,IAAI,IAAI,CAAE;AAC9C;;;ACFO,SAAS,aAAa,MAAwB;AACnD,SAAO,KAAK,OAAO,CAAC,GAAG,MAAO,IAAI,IAAI,IAAI,CAAE;AAC9C;;;ACFO,SAAS,WAAW,GAAW,GAAuB;AAC3D,SAAO,IAAI,IAAI,KAAK,IAAI,IAAI,IAAI;AAClC;;;ACFO,UAAU,MAAS,KAAmB,GAA0C;AACrF,WAAS,IAAI,GAAG,IAAI,IAAI,QAAQ,KAAK,GAAG;AACtC,UAAM,IAAI,MAAM,GAAG,IAAI,CAAC;AAAA,EAC1B;AACF;;;ACJO,SAAS,QACd,QACA,QAC4B;AAC5B,QAAM,MAAM,oBAAI,IAA2B;AAC3C,aAAW,SAAS,QAAQ;AAC1B,UAAM,MAAM,OAAO,KAAK;AACxB,QAAI,CAAC,IAAI,IAAI,GAAG,EAAG,KAAI,IAAI,KAAK,CAAC,CAAC;AAClC,IAAC,IAAI,IAAI,GAAG,EAAc,KAAK,KAAK;AAAA,EACtC;AACA,SAAO;AACT;;;ACXO,SAAS,SAAY,OAAa;AACvC,SAAO;AACT;;;ACDO,SAAS,SAAe,OAAe,OAA2B;AACvE,SAAO,MAAM,SAAS,KAAK;AAC7B;;;ACHO,SAAS,OAAO,SAAiB,cAAc,MAAc;AAClE,SAAO,QAAQ,WAAW,WAAW,KAAK,WAAW,EAAE;AACzD;;;ACFO,SAAS,UAAa,UAAwC;AACnE,SAAO,aAAa;AACtB;;;ACFO,SAAS,UAAa,UAAmC;AAC9D,SAAO,aAAa;AACtB;;;ACFA,eAAsB,gBAAmB,UAAmD;AAC1F,QAAM,QAAa,CAAC;AACpB,mBAAiB,QAAQ,UAAU;AACjC,UAAM,KAAK,IAAI;AAAA,EACjB;AACA,SAAO;AACT;;;ACHO,SAAS,UAGd,QAAgB,UAAwF;AACxG,SAAO,OAAO;AAAA,IACZ,OAAO,QAAQ,MAAM,EAAE,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM,CAAC,KAAK,SAAS,OAA+B,GAAG,CAAC,CAAC;AAAA,EAClG;AACF;;;ACVO,SAAS,OAAc,QAA4C;AACxE,SAAO,MAAM,KAAK,IAAI,IAAI,MAAM,CAAC;AACnC;;;ACFO,SAAS,SAAqB,QAA0B,QAAiD;AAC9G,QAAM,MAAM,oBAAI,IAAgB;AAChC,aAAW,SAAS,QAAQ;AAC1B,UAAM,MAAM,OAAO,KAAK;AACxB,QAAI,CAAC,IAAI,IAAI,GAAG,GAAG;AACjB,UAAI,IAAI,KAAK,KAAK;AAAA,IACpB;AAAA,EACF;AACA,SAAO,MAAM,KAAK,IAAI,OAAO,CAAC;AAChC;;;ACTO,SAAS,KAAK,IAA2B;AAC9C,SAAO,IAAI,QAAc,CAAC,YAAY,WAAW,MAAM,QAAQ,GAAG,EAAE,CAAC;AACvE;;;ACFO,SAAS,cAA6B;AAC3C,SAAO,IAAI,QAAc,CAAC,YAAY;AACpC,QAAI,OAAO,wBAAwB,aAAa;AAC9C,0BAAoB,MAAM,QAAQ,CAAC;AAAA,IACrC,OAAO;AACL,iBAAW,MAAM,QAAQ,GAAG,CAAC;AAAA,IAC/B;AAAA,EACF,CAAC;AACH;","names":[]}
|
package/dist/codegen.d.ts
CHANGED
|
@@ -211,11 +211,11 @@ declare function formatTypescript(content: string): Promise<string>;
|
|
|
211
211
|
|
|
212
212
|
/**
|
|
213
213
|
* Formats solidity code using prettier and write it to a file
|
|
214
|
-
* @param
|
|
214
|
+
* @param content solidity code
|
|
215
215
|
* @param fullOutputPath full path to the output file
|
|
216
216
|
* @param logPrefix prefix for debug logs
|
|
217
217
|
*/
|
|
218
|
-
declare function formatAndWriteSolidity(
|
|
218
|
+
declare function formatAndWriteSolidity(content: string, fullOutputPath: string, logPrefix: string): Promise<void>;
|
|
219
219
|
/**
|
|
220
220
|
* Formats typescript code using prettier and write it to a file
|
|
221
221
|
* @param output typescript code
|
package/dist/codegen.js
CHANGED
|
@@ -10,8 +10,7 @@ import {
|
|
|
10
10
|
} from "./chunk-GRGLAPN2.js";
|
|
11
11
|
import {
|
|
12
12
|
isDefined
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import "./chunk-CHXZROA7.js";
|
|
13
|
+
} from "./chunk-ETXWXV5T.js";
|
|
15
14
|
|
|
16
15
|
// src/codegen/render-solidity/abiToInterface.ts
|
|
17
16
|
import { formatAbiItem, formatAbiParameter } from "abitype";
|
|
@@ -738,10 +737,15 @@ debug2.log = console.debug.bind(console);
|
|
|
738
737
|
error.log = console.error.bind(console);
|
|
739
738
|
|
|
740
739
|
// src/codegen/utils/formatAndWrite.ts
|
|
741
|
-
async function formatAndWriteSolidity(
|
|
742
|
-
|
|
740
|
+
async function formatAndWriteSolidity(content, fullOutputPath, logPrefix) {
|
|
741
|
+
let output = content;
|
|
742
|
+
try {
|
|
743
|
+
output = await formatSolidity(output);
|
|
744
|
+
} catch (e) {
|
|
745
|
+
error(`Error while attempting to format ${fullOutputPath}`, e);
|
|
746
|
+
}
|
|
743
747
|
await fs.mkdir(path2.dirname(fullOutputPath), { recursive: true });
|
|
744
|
-
await fs.writeFile(fullOutputPath,
|
|
748
|
+
await fs.writeFile(fullOutputPath, output);
|
|
745
749
|
debug2(`${logPrefix}: ${fullOutputPath}`);
|
|
746
750
|
}
|
|
747
751
|
async function formatAndWriteTypescript(output, fullOutputPath, logPrefix) {
|