@railgun-community/shared-models 5.7.4 → 5.7.6
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/models/balance.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ export declare enum RailgunWalletBalanceBucket {
|
|
|
2
2
|
Spendable = "Spendable",
|
|
3
3
|
ShieldBlocked = "ShieldBlocked",
|
|
4
4
|
ShieldPending = "ShieldPending",
|
|
5
|
-
|
|
5
|
+
ProofSubmitted = "ProofSubmitted",
|
|
6
6
|
MissingInternalPOI = "MissingInternalPOI",
|
|
7
7
|
MissingExternalPOI = "MissingExternalPOI"
|
|
8
8
|
}
|
package/dist/models/balance.js
CHANGED
|
@@ -6,7 +6,7 @@ var RailgunWalletBalanceBucket;
|
|
|
6
6
|
RailgunWalletBalanceBucket["Spendable"] = "Spendable";
|
|
7
7
|
RailgunWalletBalanceBucket["ShieldBlocked"] = "ShieldBlocked";
|
|
8
8
|
RailgunWalletBalanceBucket["ShieldPending"] = "ShieldPending";
|
|
9
|
-
RailgunWalletBalanceBucket["
|
|
9
|
+
RailgunWalletBalanceBucket["ProofSubmitted"] = "ProofSubmitted";
|
|
10
10
|
RailgunWalletBalanceBucket["MissingInternalPOI"] = "MissingInternalPOI";
|
|
11
11
|
RailgunWalletBalanceBucket["MissingExternalPOI"] = "MissingExternalPOI";
|
|
12
12
|
})(RailgunWalletBalanceBucket || (exports.RailgunWalletBalanceBucket = RailgunWalletBalanceBucket = {}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"balance.js","sourceRoot":"","sources":["../../src/models/balance.ts"],"names":[],"mappings":";;;AAAA,IAAY,0BAOX;AAPD,WAAY,0BAA0B;IACpC,qDAAuB,CAAA;IACvB,6DAA+B,CAAA;IAC/B,6DAA+B,CAAA;IAC/B,+
|
|
1
|
+
{"version":3,"file":"balance.js","sourceRoot":"","sources":["../../src/models/balance.ts"],"names":[],"mappings":";;;AAAA,IAAY,0BAOX;AAPD,WAAY,0BAA0B;IACpC,qDAAuB,CAAA;IACvB,6DAA+B,CAAA;IAC/B,6DAA+B,CAAA;IAC/B,+DAAiC,CAAA;IACjC,uEAAyC,CAAA;IACzC,uEAAyC,CAAA;AAC3C,CAAC,EAPW,0BAA0B,0CAA1B,0BAA0B,QAOrC","sourcesContent":["export enum RailgunWalletBalanceBucket {\n Spendable = 'Spendable',\n ShieldBlocked = 'ShieldBlocked',\n ShieldPending = 'ShieldPending',\n ProofSubmitted = 'ProofSubmitted',\n MissingInternalPOI = 'MissingInternalPOI', // Change or DeFi interaction (Swap receipt)\n MissingExternalPOI = 'MissingExternalPOI',\n}\n"]}
|
|
@@ -48,9 +48,10 @@ export type Chain = {
|
|
|
48
48
|
export type RailgunBalancesEvent = {
|
|
49
49
|
txidVersion: TXIDVersion;
|
|
50
50
|
chain: Chain;
|
|
51
|
+
railgunWalletID: string;
|
|
52
|
+
balanceBucket: RailgunWalletBalanceBucket;
|
|
51
53
|
erc20Amounts: RailgunERC20Amount[];
|
|
52
54
|
nftAmounts: RailgunNFTAmount[];
|
|
53
|
-
railgunWalletID: string;
|
|
54
55
|
};
|
|
55
56
|
export declare enum POIProofEventStatus {
|
|
56
57
|
LoadingNextBatch = "LoadingNextBatch",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":";;;AAYA;;;GAGG;AACH,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,0BAAV,UAAU,QAIrB;AA+BD,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;
|
|
1
|
+
{"version":3,"file":"response-types.js","sourceRoot":"","sources":["../../src/models/response-types.ts"],"names":[],"mappings":";;;AAYA;;;GAGG;AACH,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,6CAAS,CAAA;IACT,6CAAS,CAAA;IACT,6CAAS,CAAA;AACX,CAAC,EAJW,UAAU,0BAAV,UAAU,QAIrB;AA+BD,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,uCAAO,CAAA;AACT,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;AAgBD,IAAY,mBAKX;AALD,WAAY,mBAAmB;IAC7B,4DAAqC,CAAA;IACrC,gDAAyB,CAAA;IACzB,sCAAe,CAAA;IACf,gEAAyC,CAAA;AAC3C,CAAC,EALW,mBAAmB,mCAAnB,mBAAmB,QAK9B;AAgED;;GAEG;AACH,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mDAAU,CAAA;IACV,qDAAW,CAAA;AACb,CAAC,EAHW,YAAY,4BAAZ,YAAY,QAGvB;AAqFD,IAAY,8BAMX;AAND,WAAY,8BAA8B;IACxC,+DAA6B,CAAA;IAC7B,mEAAiC,CAAA;IACjC,2EAAyC,CAAA;IACzC,iFAA+C,CAAA;IAC/C,qDAAmB,CAAA;AACrB,CAAC,EANW,8BAA8B,8CAA9B,8BAA8B,QAMzC","sourcesContent":["/// <reference types=\"../types/global\" />\nimport { ContractTransaction } from 'ethers';\nimport { MerkletreeScanStatus } from './merkletree-scan';\nimport { FeesSerialized } from './network-config';\nimport { TXIDVersion } from './engine';\nimport { RailgunWalletBalanceBucket } from './balance';\n\nexport type RailgunAPICiphertext = {\n iv: string;\n data: string[];\n};\n\n/**\n * Type0 / Type1 = non-EIP-1559 (gasPrice).\n * Type2 = EIP-1559 (maxFeePerGas and maxPriorityFeePerGas).\n */\nexport enum EVMGasType {\n Type0 = 0,\n Type1 = 1,\n Type2 = 2,\n}\n\nexport type TransactionGasDetails =\n | TransactionGasDetailsType0\n | TransactionGasDetailsType1\n | TransactionGasDetailsType2;\n\nexport type TransactionGasDetailsType0 = {\n evmGasType: EVMGasType.Type0;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType1 = {\n evmGasType: EVMGasType.Type1;\n gasEstimate: bigint;\n gasPrice: bigint;\n};\n\nexport type TransactionGasDetailsType2 = {\n evmGasType: EVMGasType.Type2;\n gasEstimate: bigint;\n maxFeePerGas: bigint;\n maxPriorityFeePerGas: bigint;\n};\n\nexport type FeeTokenDetails = {\n tokenAddress: string;\n feePerUnitGas: bigint;\n};\n\nexport enum ChainType {\n EVM = 0,\n}\n\nexport type Chain = {\n type: ChainType;\n id: number;\n};\n\nexport type RailgunBalancesEvent = {\n txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n balanceBucket: RailgunWalletBalanceBucket;\n erc20Amounts: RailgunERC20Amount[];\n nftAmounts: RailgunNFTAmount[];\n};\n\nexport enum POIProofEventStatus {\n LoadingNextBatch = 'LoadingNextBatch',\n InProgress = 'InProgress',\n Error = 'Error',\n AllProofsCompleted = 'AllProofsCompleted',\n}\n\nexport type POIProofProgressEvent = {\n status: POIProofEventStatus;\n txidVersion: TXIDVersion;\n chain: Chain;\n railgunWalletID: string;\n progress: number;\n listKey: string;\n txid: string;\n railgunTxid: string;\n index: number;\n totalCount: number;\n errMessage: Optional<string>;\n};\n\nexport type MerkletreeScanUpdateEvent = {\n chain: Chain;\n scanStatus: MerkletreeScanStatus;\n progress: number;\n};\n\nexport type LoadProviderResponse = {\n feesSerialized: FeesSerialized;\n};\n\nexport type RailgunWalletInfo = {\n id: string;\n railgunAddress: string;\n};\n\nexport type RailgunWalletAddressData = {\n masterPublicKey: bigint;\n viewingPublicKey: bigint;\n};\n\nexport type RailgunTxidFromNullifiersResponse = {\n txid?: string;\n};\n\nexport type RailgunPopulateTransactionResponse = {\n transaction: ContractTransaction;\n nullifiers?: string[];\n};\n\nexport type RailgunTransactionGasEstimateResponse = {\n gasEstimate: bigint;\n relayerFeeCommitment?: CommitmentSummary;\n};\n\nexport type RailgunERC20Recipient = {\n tokenAddress: string;\n recipientAddress: string;\n};\n\nexport type RailgunERC20Amount = {\n tokenAddress: string;\n amount: bigint;\n};\n\nexport type RailgunERC20AmountRecipient = RailgunERC20Amount & {\n recipientAddress: string;\n};\n\n/**\n * Synced NFT types from TokenType (@railgun-community/engine).\n */\nexport enum NFTTokenType {\n ERC721 = 1,\n ERC1155 = 2,\n}\n\nexport type NFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amountString: string;\n};\n\nexport type NFTAmountRecipient = NFTAmount & {\n recipientAddress: string;\n};\n\nexport type RailgunNFTAmount = {\n nftAddress: string;\n nftTokenType: NFTTokenType;\n tokenSubID: string;\n amount: bigint;\n};\n\nexport type RailgunNFTAmountRecipient = RailgunNFTAmount & {\n recipientAddress: string;\n};\n\nexport type EncryptDataWithSharedKeyResponse = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: Uint8Array;\n};\n\nexport type EncryptDataWithSharedKeySerialized = {\n encryptedData: [string, string];\n randomPubKey: string;\n sharedKey: string;\n};\n\nexport type Pbkdf2Response = string;\n\ntype SendAdditionalData = {\n recipientAddress: Optional<string>;\n walletSource: Optional<string>;\n memoText: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n};\n\ntype HistoryAdditionalData = {\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryERC20Amount = RailgunERC20Amount &\n HistoryAdditionalData;\n\nexport type RailgunHistoryNFTAmount = RailgunNFTAmount & HistoryAdditionalData;\n\nexport type RailgunHistorySendERC20Amount = RailgunHistoryERC20Amount &\n SendAdditionalData;\n\nexport type RailgunHistorySendNFTAmount = RailgunHistoryNFTAmount &\n SendAdditionalData;\n\ntype UnshieldAdditonalData = {\n unshieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n};\n\nexport type RailgunHistoryUnshieldERC20Amount = RailgunHistorySendERC20Amount &\n UnshieldAdditonalData;\n\nexport type RailgunHistoryUnshieldNFTAmount = RailgunHistorySendNFTAmount &\n UnshieldAdditonalData;\n\ntype ReceiveAdditionalData = {\n senderAddress: Optional<string>;\n memoText: Optional<string>;\n shieldFee: Optional<string>;\n hasValidPOIForActiveLists: boolean;\n balanceBucket: RailgunWalletBalanceBucket;\n};\n\nexport type RailgunHistoryReceiveERC20Amount = RailgunHistoryERC20Amount &\n ReceiveAdditionalData;\n\nexport type RailgunHistoryReceiveNFTAmount = RailgunHistoryNFTAmount &\n ReceiveAdditionalData;\n\nexport enum TransactionHistoryItemCategory {\n ShieldERC20s = 'ShieldERC20s',\n UnshieldERC20s = 'UnshieldERC20s',\n TransferSendERC20s = 'TransferSendERC20s',\n TransferReceiveERC20s = 'TransferReceiveERC20s',\n Unknown = 'Unknown',\n}\n\nexport type TransactionHistoryItem = {\n txid: string;\n version: number;\n timestamp: Optional<number>;\n blockNumber: Optional<number>;\n receiveERC20Amounts: RailgunHistoryReceiveERC20Amount[];\n transferERC20Amounts: RailgunHistorySendERC20Amount[];\n changeERC20Amounts: RailgunHistoryERC20Amount[];\n relayerFeeERC20Amount?: RailgunHistoryERC20Amount;\n unshieldERC20Amounts: RailgunHistoryUnshieldERC20Amount[];\n receiveNFTAmounts: RailgunHistoryReceiveNFTAmount[];\n transferNFTAmounts: RailgunHistorySendNFTAmount[];\n unshieldNFTAmounts: RailgunHistoryUnshieldNFTAmount[];\n category: TransactionHistoryItemCategory;\n};\n\ntype Ciphertext = {\n iv: string;\n tag: string;\n data: string[];\n};\n\nexport type CommitmentCiphertext = {\n ciphertext: Ciphertext;\n blindedSenderViewingKey: string;\n blindedReceiverViewingKey: string;\n annotationData: string;\n memo: string;\n};\n\nexport type CommitmentSummary = {\n commitmentCiphertext: CommitmentCiphertext;\n commitmentHash: string;\n};\n"]}
|