wative-core 2.2.1 → 2.4.0

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.
Files changed (36) hide show
  1. package/CHANGELOG.md +634 -13
  2. package/LICENSE +114 -0
  3. package/README.md +144 -5
  4. package/dist/artifacts/evm/index.cjs +1 -1
  5. package/dist/artifacts/evm/index.d.cts +2 -2
  6. package/dist/artifacts/evm/index.d.ts +2 -2
  7. package/dist/artifacts/evm/index.js +1 -1
  8. package/dist/artifacts/svm/index.cjs +1 -1
  9. package/dist/artifacts/svm/index.d.cts +3 -3
  10. package/dist/artifacts/svm/index.d.ts +3 -3
  11. package/dist/artifacts/svm/index.js +1 -1
  12. package/dist/{container-provider-C59yqd5Z.d.ts → container-provider-D2QluIe_.d.ts} +10 -3
  13. package/dist/{container-provider-i614LDE1.d.cts → container-provider-DAUXclw_.d.cts} +10 -3
  14. package/dist/{evm-BLml33LX.d.cts → evm-GxBuNjq7.d.ts} +2 -2
  15. package/dist/{evm-DTzqGlL6.d.ts → evm-qXdZWugm.d.cts} +2 -2
  16. package/dist/{file-sink-B73MuigK.d.cts → file-sink-B0EjCBvG.d.ts} +8 -5
  17. package/dist/{file-sink-LS4hyXXi.d.ts → file-sink-DSOZbsJM.d.cts} +8 -5
  18. package/dist/index.cjs +1 -1
  19. package/dist/index.d.cts +25 -8
  20. package/dist/index.d.ts +25 -8
  21. package/dist/index.js +1 -1
  22. package/dist/index.node.cjs +1 -1
  23. package/dist/index.node.d.cts +6 -6
  24. package/dist/index.node.d.ts +6 -6
  25. package/dist/index.node.js +1 -1
  26. package/dist/node/index.cjs +1 -1
  27. package/dist/node/index.d.cts +3 -3
  28. package/dist/node/index.d.ts +3 -3
  29. package/dist/node/index.js +1 -1
  30. package/dist/{svm-DieFbh9k.d.ts → svm-B_c0L-rJ.d.cts} +2 -2
  31. package/dist/{svm-CCzqNAWM.d.cts → svm-Ca4Xyw0Y.d.ts} +2 -2
  32. package/dist/{workspace-CamTHxso.d.cts → workspace-DdaY7sWa.d.cts} +23 -4
  33. package/dist/{workspace-CamTHxso.d.ts → workspace-DdaY7sWa.d.ts} +23 -4
  34. package/examples/15-package-resolution.test.cjs +187 -1
  35. package/examples/18-envelope-v3.test.cjs +106 -0
  36. package/package.json +6 -3
package/dist/index.d.cts CHANGED
@@ -1,9 +1,9 @@
1
- import { P as Provider, w as RecordType, z as Slug, R as Record$1, i as ChainVM } from './workspace-CamTHxso.cjs';
2
- export { A as Account, a as AccountCollection, b as AccountOrgType, c as Address, d as Asset, e as AssetBalance, f as AssetCollection, g as AssetId, h as AssetInitObject, C as ChainId, j as ConsoleSink, E as EvmAddress, k as EvmRawTx, l as EvmTransaction, m as EvmTxBuildParams, n as EvmTxType, L as LogLevel, o as LogRecord, p as LogSink, q as Logger, r as LoggerConfig, N as Network, s as NetworkCollection, t as NetworkInit, u as NetworkLike, v as RecordInit, S as Settling, x as SimulationResult, y as SinkConfig, B as SvmAddress, D as SvmTransaction, F as SvmTxBuildParams, T as Transaction, G as TransactionReceipt, H as TransactionStateChange, I as TransactionStatus, J as TransactionTracker, W as Wallet, K as WalletCollection, M as WativeError, O as WativeErrorCode, Q as WativeErrorOpts, U as Workspace, V as WorkspaceConfig, X as newMnemonic } from './workspace-CamTHxso.cjs';
3
- import { a as ContainerProvider } from './container-provider-i614LDE1.cjs';
4
- export { C as ContainerEntry } from './container-provider-i614LDE1.cjs';
5
- export { C as Contract } from './evm-BLml33LX.cjs';
6
- export { P as Program, S as SvmInstruction } from './svm-CCzqNAWM.cjs';
1
+ import { P as Provider, x as RecordType, B as Slug, R as Record$1, i as ChainVM } from './workspace-DdaY7sWa.cjs';
2
+ export { A as Account, a as AccountCollection, b as AccountOrgType, c as Address, d as Asset, e as AssetBalance, f as AssetCollection, g as AssetId, h as AssetInitObject, C as ChainId, j as ConsoleSink, k as ContainerState, E as EvmAddress, l as EvmRawTx, m as EvmTransaction, n as EvmTxBuildParams, o as EvmTxType, L as LogLevel, p as LogRecord, q as LogSink, r as Logger, s as LoggerConfig, N as Network, t as NetworkCollection, u as NetworkInit, v as NetworkLike, O as OpenOptions, w as RecordInit, S as Settling, y as SimulationResult, z as SinkConfig, D as SvmAddress, F as SvmTransaction, G as SvmTxBuildParams, T as Transaction, H as TransactionReceipt, I as TransactionStateChange, J as TransactionStatus, K as TransactionTracker, W as Wallet, M as WalletCollection, Q as WativeError, U as WativeErrorCode, V as WativeErrorOpts, X as Workspace, Y as WorkspaceConfig, Z as newMnemonic } from './workspace-DdaY7sWa.cjs';
3
+ import { a as ContainerProvider } from './container-provider-DAUXclw_.cjs';
4
+ export { C as ContainerEntry } from './container-provider-DAUXclw_.cjs';
5
+ export { A as AbiItem, C as Contract } from './evm-qXdZWugm.cjs';
6
+ export { P as Program, S as SvmInstruction } from './svm-B_c0L-rJ.cjs';
7
7
 
8
8
  type StorageDurability = "persistent" | "best-effort";
9
9
  interface IdbProviderOptions {
@@ -14,6 +14,10 @@ interface IdbProviderOptions {
14
14
 
15
15
  readonly storageManager?: Pick<StorageManager, "persist" | "persisted" | "estimate"> | null;
16
16
  }
17
+ interface IdbDestroyOptions extends Pick<IdbProviderOptions, "indexedDB"> {
18
+
19
+ readonly blockedTimeoutMs?: number;
20
+ }
17
21
  interface StorageQuota {
18
22
  readonly usage?: number;
19
23
  readonly quota?: number;
@@ -42,7 +46,7 @@ declare class IdbProvider extends ContainerProvider {
42
46
  protected _ensureDir(_key: string): Promise<void>;
43
47
  close(): Promise<void>;
44
48
 
45
- static destroy(databaseName: string, opts?: Pick<IdbProviderOptions, "indexedDB">): Promise<void>;
49
+ static destroy(databaseName: string, opts?: IdbDestroyOptions): Promise<void>;
46
50
  }
47
51
 
48
52
  declare class FileProvider extends Provider {
@@ -123,6 +127,19 @@ declare class Argon2Kdf extends Cipher {
123
127
  decrypt(_input: Uint8Array, _secret: Uint8Array): never;
124
128
  }
125
129
 
130
+ interface Argon2BackendInfo {
131
+
132
+ readonly backend: string;
133
+
134
+ readonly wasm: boolean;
135
+
136
+ readonly reason?: string;
137
+
138
+ readonly overrides: readonly string[];
139
+ }
140
+
141
+ declare function argon2BackendInfo(): Argon2BackendInfo;
142
+
126
143
  type PasswordWeaknessCode = "TOO_SHORT" | "NO_UPPERCASE" | "NO_LOWERCASE" | "NO_DIGIT" | "NO_SYMBOL" | "REPEATED_CHARS" | "SEQUENTIAL_CHARS" | "USERNAME_SUBSTRING" | "FORBIDDEN_WORD" | "REUSED_FROM_HISTORY" | "LEADING_TRAILING_WHITESPACE" | "MIXED_UNICODE_NORMALIZATION" | "INVISIBLE_CHARACTERS";
127
144
  interface PasswordWeakness {
128
145
  readonly code: PasswordWeaknessCode;
@@ -191,4 +208,4 @@ interface AssetInit {
191
208
  }
192
209
  declare const BUILTIN_ASSETS: Record<string, ReadonlyArray<AssetInit>>;
193
210
 
194
- export { AesGcmCipher, type AesGcmCipherOptions, Argon2Kdf, type Argon2KdfOptions, type AssetInit, BUILTIN_ASSETS, BUILTIN_NETWORKS, ChainVM, Cipher, ContainerProvider, DbProvider, FileProvider, IdbProvider, type IdbProviderOptions, type PasswordCheckResult, PasswordPolicy, type PasswordPolicyOptions, PasswordScore, type PasswordWeakness, type PasswordWeaknessCode, Provider, Record$1 as Record, RecordType, Slug, type StorageDurability, type StorageQuota };
211
+ export { AesGcmCipher, type AesGcmCipherOptions, type Argon2BackendInfo, Argon2Kdf, type Argon2KdfOptions, type AssetInit, BUILTIN_ASSETS, BUILTIN_NETWORKS, ChainVM, Cipher, ContainerProvider, DbProvider, FileProvider, type IdbDestroyOptions, IdbProvider, type IdbProviderOptions, type NetworkConfig, type PasswordCheckContext, type PasswordCheckResult, PasswordPolicy, type PasswordPolicyOptions, PasswordScore, type PasswordWeakness, type PasswordWeaknessCode, Provider, Record$1 as Record, RecordType, Slug, type StorageDurability, type StorageQuota, argon2BackendInfo };
package/dist/index.d.ts CHANGED
@@ -1,9 +1,9 @@
1
- import { P as Provider, w as RecordType, z as Slug, R as Record$1, i as ChainVM } from './workspace-CamTHxso.js';
2
- export { A as Account, a as AccountCollection, b as AccountOrgType, c as Address, d as Asset, e as AssetBalance, f as AssetCollection, g as AssetId, h as AssetInitObject, C as ChainId, j as ConsoleSink, E as EvmAddress, k as EvmRawTx, l as EvmTransaction, m as EvmTxBuildParams, n as EvmTxType, L as LogLevel, o as LogRecord, p as LogSink, q as Logger, r as LoggerConfig, N as Network, s as NetworkCollection, t as NetworkInit, u as NetworkLike, v as RecordInit, S as Settling, x as SimulationResult, y as SinkConfig, B as SvmAddress, D as SvmTransaction, F as SvmTxBuildParams, T as Transaction, G as TransactionReceipt, H as TransactionStateChange, I as TransactionStatus, J as TransactionTracker, W as Wallet, K as WalletCollection, M as WativeError, O as WativeErrorCode, Q as WativeErrorOpts, U as Workspace, V as WorkspaceConfig, X as newMnemonic } from './workspace-CamTHxso.js';
3
- import { a as ContainerProvider } from './container-provider-C59yqd5Z.js';
4
- export { C as ContainerEntry } from './container-provider-C59yqd5Z.js';
5
- export { C as Contract } from './evm-DTzqGlL6.js';
6
- export { P as Program, S as SvmInstruction } from './svm-DieFbh9k.js';
1
+ import { P as Provider, x as RecordType, B as Slug, R as Record$1, i as ChainVM } from './workspace-DdaY7sWa.js';
2
+ export { A as Account, a as AccountCollection, b as AccountOrgType, c as Address, d as Asset, e as AssetBalance, f as AssetCollection, g as AssetId, h as AssetInitObject, C as ChainId, j as ConsoleSink, k as ContainerState, E as EvmAddress, l as EvmRawTx, m as EvmTransaction, n as EvmTxBuildParams, o as EvmTxType, L as LogLevel, p as LogRecord, q as LogSink, r as Logger, s as LoggerConfig, N as Network, t as NetworkCollection, u as NetworkInit, v as NetworkLike, O as OpenOptions, w as RecordInit, S as Settling, y as SimulationResult, z as SinkConfig, D as SvmAddress, F as SvmTransaction, G as SvmTxBuildParams, T as Transaction, H as TransactionReceipt, I as TransactionStateChange, J as TransactionStatus, K as TransactionTracker, W as Wallet, M as WalletCollection, Q as WativeError, U as WativeErrorCode, V as WativeErrorOpts, X as Workspace, Y as WorkspaceConfig, Z as newMnemonic } from './workspace-DdaY7sWa.js';
3
+ import { a as ContainerProvider } from './container-provider-D2QluIe_.js';
4
+ export { C as ContainerEntry } from './container-provider-D2QluIe_.js';
5
+ export { A as AbiItem, C as Contract } from './evm-GxBuNjq7.js';
6
+ export { P as Program, S as SvmInstruction } from './svm-Ca4Xyw0Y.js';
7
7
 
8
8
  type StorageDurability = "persistent" | "best-effort";
9
9
  interface IdbProviderOptions {
@@ -14,6 +14,10 @@ interface IdbProviderOptions {
14
14
 
15
15
  readonly storageManager?: Pick<StorageManager, "persist" | "persisted" | "estimate"> | null;
16
16
  }
17
+ interface IdbDestroyOptions extends Pick<IdbProviderOptions, "indexedDB"> {
18
+
19
+ readonly blockedTimeoutMs?: number;
20
+ }
17
21
  interface StorageQuota {
18
22
  readonly usage?: number;
19
23
  readonly quota?: number;
@@ -42,7 +46,7 @@ declare class IdbProvider extends ContainerProvider {
42
46
  protected _ensureDir(_key: string): Promise<void>;
43
47
  close(): Promise<void>;
44
48
 
45
- static destroy(databaseName: string, opts?: Pick<IdbProviderOptions, "indexedDB">): Promise<void>;
49
+ static destroy(databaseName: string, opts?: IdbDestroyOptions): Promise<void>;
46
50
  }
47
51
 
48
52
  declare class FileProvider extends Provider {
@@ -123,6 +127,19 @@ declare class Argon2Kdf extends Cipher {
123
127
  decrypt(_input: Uint8Array, _secret: Uint8Array): never;
124
128
  }
125
129
 
130
+ interface Argon2BackendInfo {
131
+
132
+ readonly backend: string;
133
+
134
+ readonly wasm: boolean;
135
+
136
+ readonly reason?: string;
137
+
138
+ readonly overrides: readonly string[];
139
+ }
140
+
141
+ declare function argon2BackendInfo(): Argon2BackendInfo;
142
+
126
143
  type PasswordWeaknessCode = "TOO_SHORT" | "NO_UPPERCASE" | "NO_LOWERCASE" | "NO_DIGIT" | "NO_SYMBOL" | "REPEATED_CHARS" | "SEQUENTIAL_CHARS" | "USERNAME_SUBSTRING" | "FORBIDDEN_WORD" | "REUSED_FROM_HISTORY" | "LEADING_TRAILING_WHITESPACE" | "MIXED_UNICODE_NORMALIZATION" | "INVISIBLE_CHARACTERS";
127
144
  interface PasswordWeakness {
128
145
  readonly code: PasswordWeaknessCode;
@@ -191,4 +208,4 @@ interface AssetInit {
191
208
  }
192
209
  declare const BUILTIN_ASSETS: Record<string, ReadonlyArray<AssetInit>>;
193
210
 
194
- export { AesGcmCipher, type AesGcmCipherOptions, Argon2Kdf, type Argon2KdfOptions, type AssetInit, BUILTIN_ASSETS, BUILTIN_NETWORKS, ChainVM, Cipher, ContainerProvider, DbProvider, FileProvider, IdbProvider, type IdbProviderOptions, type PasswordCheckResult, PasswordPolicy, type PasswordPolicyOptions, PasswordScore, type PasswordWeakness, type PasswordWeaknessCode, Provider, Record$1 as Record, RecordType, Slug, type StorageDurability, type StorageQuota };
211
+ export { AesGcmCipher, type AesGcmCipherOptions, type Argon2BackendInfo, Argon2Kdf, type Argon2KdfOptions, type AssetInit, BUILTIN_ASSETS, BUILTIN_NETWORKS, ChainVM, Cipher, ContainerProvider, DbProvider, FileProvider, type IdbDestroyOptions, IdbProvider, type IdbProviderOptions, type NetworkConfig, type PasswordCheckContext, type PasswordCheckResult, PasswordPolicy, type PasswordPolicyOptions, PasswordScore, type PasswordWeakness, type PasswordWeaknessCode, Provider, Record$1 as Record, RecordType, Slug, type StorageDurability, type StorageQuota, argon2BackendInfo };