@parity/product-sdk-contracts 0.6.2 → 0.7.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.
- package/README.md +34 -21
- package/dist/codegen.d.ts +1 -1
- package/dist/index.d.ts +34 -7
- package/dist/index.js +156 -19
- package/dist/index.js.map +1 -1
- package/dist/pvm.d.ts +1 -1
- package/dist/{types-DzYW54TT.d.ts → types-BJl1dir8.d.ts} +15 -13
- package/package.json +9 -9
package/dist/pvm.d.ts
CHANGED
|
@@ -219,11 +219,7 @@ declare function ensureContractAccountMapped(runtime: ContractRuntime, address:
|
|
|
219
219
|
onStatus?: (s: string) => void;
|
|
220
220
|
}): Promise<TxResult | null>;
|
|
221
221
|
|
|
222
|
-
|
|
223
|
-
interface CdmJsonTarget {
|
|
224
|
-
"asset-hub": string;
|
|
225
|
-
bulletin: string;
|
|
226
|
-
}
|
|
222
|
+
type CdmJsonDependencyVersion = number | string;
|
|
227
223
|
/**
|
|
228
224
|
* A deployed contract's on-chain address, ABI, and optional metadata CID.
|
|
229
225
|
*
|
|
@@ -237,11 +233,11 @@ interface CdmJsonContract {
|
|
|
237
233
|
abi: AbiEntry[];
|
|
238
234
|
metadataCid?: string;
|
|
239
235
|
}
|
|
240
|
-
/** A project's `cdm.json` manifest
|
|
236
|
+
/** A project's `cdm.json` manifest. */
|
|
241
237
|
interface CdmJson {
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
238
|
+
dependencies: Record<string, CdmJsonDependencyVersion>;
|
|
239
|
+
contracts?: Record<string, CdmJsonContract>;
|
|
240
|
+
registry?: HexString;
|
|
245
241
|
}
|
|
246
242
|
/** An ABI parameter or return value, with support for nested tuple and struct types. */
|
|
247
243
|
interface AbiParam {
|
|
@@ -376,9 +372,15 @@ interface ContractOptions {
|
|
|
376
372
|
defaultSigner?: PolkadotSigner;
|
|
377
373
|
}
|
|
378
374
|
/** Options for {@link ContractManager} construction. */
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
375
|
+
type ContractManagerOptions = ContractOptions;
|
|
376
|
+
/** Options for resolving installed CDM contract addresses from the live CDM registry. */
|
|
377
|
+
interface LiveContractResolutionOptions {
|
|
378
|
+
/** CDM registry contract address. Defaults to `cdm.json.registry`. */
|
|
379
|
+
registryAddress?: HexString;
|
|
380
|
+
/** Subset of installed libraries to resolve. Defaults to every contract in the manifest. */
|
|
381
|
+
libraries?: readonly string[];
|
|
382
|
+
/** Origin used for CDM registry dry-run queries. Defaults to `defaultOrigin` in manager helpers. */
|
|
383
|
+
registryOrigin?: SS58String;
|
|
382
384
|
}
|
|
383
385
|
/**
|
|
384
386
|
* A typed contract handle where each ABI method exposes `.query()` and `.tx()`.
|
|
@@ -432,4 +434,4 @@ type Contract<C extends ContractDef> = {
|
|
|
432
434
|
};
|
|
433
435
|
};
|
|
434
436
|
|
|
435
|
-
export { type AbiEntry as A, type CdmJson as C, type PrepareOptions as P, type QueryOptions as Q, type ReviveDryRunCall as R, type TxOptions as T, type ContractRuntime as a, type ContractManagerOptions as b, type ContractDefaults as c, type ContractRuntimeOptions as d, type Contracts as e, type Contract as f, type ContractDef as g, type ContractOptions as h, type AbiParam as i, type CdmJsonContract as j, type
|
|
437
|
+
export { type AbiEntry as A, type CdmJson as C, type LiveContractResolutionOptions as L, type PrepareOptions as P, type QueryOptions as Q, type ReviveDryRunCall as R, type TxOptions as T, type ContractRuntime as a, type ContractManagerOptions as b, type ContractDefaults as c, type ContractRuntimeOptions as d, type Contracts as e, type Contract as f, type ContractDef as g, type ContractOptions as h, type AbiParam as i, type CdmJsonContract as j, type CdmJsonDependencyVersion as k, type ContractDryRunAt as l, type QueryResult as m, type ReviveDryRunCallOptions as n, type ReviveDryRunResult as o, type ReviveTypedApi as p, createContractRuntime as q, createContractRuntimeFromClient as r, ensureContractAccountMapped as s };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@parity/product-sdk-contracts",
|
|
3
3
|
"description": "Typed contract interactions on Polkadot Asset Hub",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.7.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
@@ -27,17 +27,17 @@
|
|
|
27
27
|
"access": "public"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@polkadot-labs/hdkd-helpers": "^0.0.
|
|
31
|
-
"polkadot-api": "^2.1.
|
|
32
|
-
"viem": "^2.
|
|
33
|
-
"@parity/product-sdk-
|
|
34
|
-
"@parity/product-sdk-keys": "0.3.2",
|
|
35
|
-
"@parity/product-sdk-signer": "0.5.0",
|
|
30
|
+
"@polkadot-labs/hdkd-helpers": "^0.0.30",
|
|
31
|
+
"polkadot-api": "^2.1.5",
|
|
32
|
+
"viem": "^2.52.0",
|
|
33
|
+
"@parity/product-sdk-keys": "0.3.3",
|
|
36
34
|
"@parity/product-sdk-logger": "0.1.1",
|
|
37
|
-
"@parity/product-sdk-
|
|
35
|
+
"@parity/product-sdk-signer": "0.6.0",
|
|
36
|
+
"@parity/product-sdk-address": "0.1.1",
|
|
37
|
+
"@parity/product-sdk-tx": "0.2.7"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
|
-
"tsup": "^8.
|
|
40
|
+
"tsup": "^8.5.1",
|
|
41
41
|
"typescript": "^5.9.3",
|
|
42
42
|
"vitest": "^3.1.4"
|
|
43
43
|
},
|