Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
878f631745 | ||
|
|
d7753839a2 | ||
|
|
fc74d88bbb | ||
|
|
47bbeee14b | ||
|
|
ba01620ba1 | ||
|
|
6e66387a8d | ||
|
|
c58687b3c6 | ||
|
|
2801088b0a | ||
|
|
fc5af92a03 | ||
|
|
8f8bb2aa23 | ||
|
|
3f69b3fc73 | ||
|
|
4ea170a83a |
+15
-2
@@ -1,8 +1,21 @@
|
||||
# CHANGELOG
|
||||
|
||||
## 6.0.5 Sep 20, 2012
|
||||
## 6.1.1 Sep 27, 2021
|
||||
|
||||
Upgrade priority: Low. Recommended for all users on 6.0.3 using `api.query.*.*.at` calls
|
||||
Contributed:
|
||||
|
||||
- Adjust bridges `OutboundLaneData` type (Thanks to https://github.com/HackFisher)
|
||||
- Fix README 404 (Thanks to https://github.com/nblogist)
|
||||
|
||||
Changes:
|
||||
|
||||
- Add `childstate_getStorageEntries` RPC
|
||||
- Allow for scale-info v0 -> v1 conversion
|
||||
|
||||
|
||||
## 6.0.5 Sep 20, 2021
|
||||
|
||||
Upgrade priority: Low. Recommended for all users on 6.0.4 using `api.query.*.*.at` calls
|
||||
|
||||
Changes:
|
||||
|
||||
|
||||
+3
-3
@@ -29,12 +29,12 @@
|
||||
"@babel/core": "^7.15.5",
|
||||
"@babel/register": "^7.15.3",
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/dev": "^0.62.67",
|
||||
"@polkadot/dev": "^0.62.68",
|
||||
"@polkadot/ts": "^0.4.8",
|
||||
"@polkadot/typegen": "workspace:packages/typegen",
|
||||
"@types/jest": "^27.0.1",
|
||||
"@types/jest": "^27.0.2",
|
||||
"copyfiles": "^2.4.1"
|
||||
},
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"packageManager": "yarn@3.0.1"
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api-contract",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Interfaces for interacting with contracts and contract ABIs",
|
||||
"main": "index.js",
|
||||
@@ -20,8 +20,8 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api-contract#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/api": "6.0.5",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/api": "6.1.1",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"rxjs": "^7.3.0"
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api-contract', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/api-contract', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api-derive",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Common functions used across Polkadot, derived from RPC calls and storage queries.",
|
||||
"main": "index.js",
|
||||
@@ -20,15 +20,15 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api-derive#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/api": "6.0.5",
|
||||
"@polkadot/rpc-core": "6.0.5",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/api": "6.1.1",
|
||||
"@polkadot/rpc-core": "6.1.1",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"@polkadot/util-crypto": "^7.4.1",
|
||||
"rxjs": "^7.3.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^7.4.1",
|
||||
"@polkadot/rpc-provider": "6.0.5"
|
||||
"@polkadot/rpc-provider": "6.1.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api-derive', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/api-derive', version: '6.1.1' };
|
||||
|
||||
@@ -7,13 +7,13 @@ The API wrappers provide a standard interface for use -
|
||||
- A static `.create(<optional ApiOptions>)` that returns an API instance when connected, decorated and ready-to use. ApiOptions can include an optional WsProvider and optional custom type definitions `{ provider: <Optional WsProvider>, types: <Optional RegistryTypes> }`.
|
||||
- The above is just a wrapper for `new Api(<optional ApiOptions>) `, exposing the `isReady` getter
|
||||
- `api.rpc.<section>.<method>` provides access to actual RPC calls, be it for queries, submission or retrieving chain information
|
||||
- [RPC (node interface)](https://polkadot.js.org/docs/substrate/rpc.html)
|
||||
- [RPC (node interface)](https://polkadot.js.org/docs/substrate/rpc)
|
||||
- `api.query.<section>.<method>` provides access to chain state queries. These are dynamically populated based on what the runtime provides
|
||||
- [Storage chain state (runtime node interface)](https://polkadot.js.org/docs/substrate/storage.html)
|
||||
- [Storage chain state (runtime node interface)](https://polkadot.js.org/docs/substrate/storage)
|
||||
- `api.tx.<section>.<method>` provides the ability to create a transaction, like chain state, this list is populated from a runtime query
|
||||
- [Extrinsics (runtime node interface)](https://polkadot.js.org/docs/substrate/extrinsics.html)
|
||||
- [Extrinsics (runtime node interface)](https://polkadot.js.org/docs/substrate/extrinsics)
|
||||
- `api.consts.<section>.<constant>` provides access to the module constants (parameter types).
|
||||
- [Constants (runtime node interface)](https://polkadot.js.org/docs/substrate/constants.html)
|
||||
- [Constants (runtime node interface)](https://polkadot.js.org/docs/substrate/constants)
|
||||
|
||||
## API Selection
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/api",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Promise and RxJS wrappers around the Polkadot JS RPC",
|
||||
"main": "index.js",
|
||||
@@ -20,12 +20,12 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/api#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/api-derive": "6.0.5",
|
||||
"@polkadot/api-derive": "6.1.1",
|
||||
"@polkadot/keyring": "^7.4.1",
|
||||
"@polkadot/rpc-core": "6.0.5",
|
||||
"@polkadot/rpc-provider": "6.0.5",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/types-known": "6.0.5",
|
||||
"@polkadot/rpc-core": "6.1.1",
|
||||
"@polkadot/rpc-provider": "6.1.1",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/types-known": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"@polkadot/util-crypto": "^7.4.1",
|
||||
"eventemitter3": "^4.0.7",
|
||||
|
||||
@@ -113,6 +113,10 @@ declare module '@polkadot/rpc-core/types.jsonrpc' {
|
||||
* Returns a child storage entry at a specific block state
|
||||
**/
|
||||
getStorage: AugmentedRpc<(childKey: PrefixedStorageKey | string | Uint8Array, key: StorageKey | string | Uint8Array | any, at?: Hash | string | Uint8Array) => Observable<Option<StorageData>>>;
|
||||
/**
|
||||
* Returns child storage entries for multiple keys at a specific block state
|
||||
**/
|
||||
getStorageEntries: AugmentedRpc<(childKey: PrefixedStorageKey | string | Uint8Array, keys: Vec<StorageKey> | (StorageKey | string | Uint8Array | any)[], at?: Hash | string | Uint8Array) => Observable<Vec<Option<StorageData>>>>;
|
||||
/**
|
||||
* Returns the hash of a child storage entry at a block state
|
||||
**/
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/api', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/api', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/rpc-core",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "A JavaScript wrapper for the Polkadot JsonRPC interface",
|
||||
"main": "index.js",
|
||||
@@ -20,8 +20,8 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/rpc-core#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/rpc-provider": "6.0.5",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/rpc-provider": "6.1.1",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"rxjs": "^7.3.0"
|
||||
},
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/rpc-core', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/rpc-core', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/rpc-provider",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Transport providers for the API",
|
||||
"main": "index.js",
|
||||
@@ -20,7 +20,7 @@
|
||||
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/rpc-provider#readme",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"@polkadot/util-crypto": "^7.4.1",
|
||||
"@polkadot/x-fetch": "^7.4.1",
|
||||
@@ -30,7 +30,7 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^7.4.1",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"mock-socket": "^9.0.3",
|
||||
"nock": "^13.1.3"
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/rpc-provider', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/rpc-provider', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/typegen",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Type generation scripts",
|
||||
"main": "index.js",
|
||||
@@ -29,17 +29,17 @@
|
||||
"@babel/core": "^7.15.5",
|
||||
"@babel/register": "^7.15.3",
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/api": "6.0.5",
|
||||
"@polkadot/rpc-provider": "6.0.5",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/types-support": "6.0.5",
|
||||
"@polkadot/api": "6.1.1",
|
||||
"@polkadot/rpc-provider": "6.1.1",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/types-support": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1",
|
||||
"handlebars": "^4.7.7",
|
||||
"websocket": "^1.0.34",
|
||||
"yargs": "^17.1.1"
|
||||
"yargs": "^17.2.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/websocket": "^1.0.4",
|
||||
"@types/yargs": "^17.0.2"
|
||||
"@types/yargs": "^17.0.3"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/typegen', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/typegen', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/types-known",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Known type definitions",
|
||||
"main": "index.js",
|
||||
@@ -21,7 +21,7 @@
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.15.4",
|
||||
"@polkadot/networks": "^7.4.1",
|
||||
"@polkadot/types": "6.0.5",
|
||||
"@polkadot/types": "6.1.1",
|
||||
"@polkadot/util": "^7.4.1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/types-known', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/types-known', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/types-support",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Supporting files for types, mostly for testing",
|
||||
"main": "index.js",
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/types-support', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/types-support', version: '6.1.1' };
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@polkadot/types",
|
||||
"version": "6.0.5",
|
||||
"version": "6.1.1",
|
||||
"type": "module",
|
||||
"description": "Implementation of the Parity codec",
|
||||
"main": "index.js",
|
||||
@@ -26,7 +26,7 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/keyring": "^7.4.1",
|
||||
"@polkadot/types-support": "6.0.5",
|
||||
"@polkadot/types-support": "6.1.1",
|
||||
"@types/bn.js": "^4.11.6",
|
||||
"bn.js": "^4.12.0"
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ import type { AuthorityIndex, AuthorityList, AuthoritySet, AuthoritySetChange, A
|
||||
import type { IdentityFields, IdentityInfo, IdentityInfoAdditional, IdentityInfoTo198, IdentityJudgement, RegistrarIndex, RegistrarInfo, Registration, RegistrationJudgement, RegistrationTo198 } from '@polkadot/types/interfaces/identity';
|
||||
import type { AuthIndex, AuthoritySignature, Heartbeat, HeartbeatTo244, OpaqueMultiaddr, OpaqueNetworkState, OpaquePeerId } from '@polkadot/types/interfaces/imOnline';
|
||||
import type { CallIndex, LotteryConfig } from '@polkadot/types/interfaces/lottery';
|
||||
import type { ErrorMetadataLatest, ErrorMetadataV10, ErrorMetadataV11, ErrorMetadataV12, ErrorMetadataV13, ErrorMetadataV14, ErrorMetadataV9, EventMetadataLatest, EventMetadataV10, EventMetadataV11, EventMetadataV12, EventMetadataV13, EventMetadataV14, EventMetadataV9, ExtrinsicMetadataLatest, ExtrinsicMetadataV11, ExtrinsicMetadataV12, ExtrinsicMetadataV13, ExtrinsicMetadataV14, FunctionArgumentMetadataLatest, FunctionArgumentMetadataV10, FunctionArgumentMetadataV11, FunctionArgumentMetadataV12, FunctionArgumentMetadataV13, FunctionArgumentMetadataV14, FunctionArgumentMetadataV9, FunctionMetadataLatest, FunctionMetadataV10, FunctionMetadataV11, FunctionMetadataV12, FunctionMetadataV13, FunctionMetadataV14, FunctionMetadataV9, MetadataAll, MetadataLatest, MetadataV10, MetadataV11, MetadataV12, MetadataV13, MetadataV14, MetadataV9, ModuleConstantMetadataV10, ModuleConstantMetadataV11, ModuleConstantMetadataV12, ModuleConstantMetadataV13, ModuleConstantMetadataV9, ModuleMetadataV10, ModuleMetadataV11, ModuleMetadataV12, ModuleMetadataV13, ModuleMetadataV9, PalletCallMetadataLatest, PalletCallMetadataV14, PalletConstantMetadataLatest, PalletConstantMetadataV14, PalletErrorMetadataLatest, PalletErrorMetadataV14, PalletEventMetadataLatest, PalletEventMetadataV14, PalletMetadataLatest, PalletMetadataV14, PalletStorageMetadataLatest, PalletStorageMetadataV14, PortableRegistry, PortableType, SignedExtensionMetadataLatest, SignedExtensionMetadataV14, StorageEntryMetadataLatest, StorageEntryMetadataV10, StorageEntryMetadataV11, StorageEntryMetadataV12, StorageEntryMetadataV13, StorageEntryMetadataV14, StorageEntryMetadataV9, StorageEntryModifierLatest, StorageEntryModifierV10, StorageEntryModifierV11, StorageEntryModifierV12, StorageEntryModifierV13, StorageEntryModifierV14, StorageEntryModifierV9, StorageEntryTypeLatest, StorageEntryTypeV10, StorageEntryTypeV11, StorageEntryTypeV12, StorageEntryTypeV13, StorageEntryTypeV14, StorageEntryTypeV9, StorageHasher, StorageHasherV10, StorageHasherV11, StorageHasherV12, StorageHasherV13, StorageHasherV14, StorageHasherV9, StorageMetadataV10, StorageMetadataV11, StorageMetadataV12, StorageMetadataV13, StorageMetadataV9 } from '@polkadot/types/interfaces/metadata';
|
||||
import type { ErrorMetadataLatest, ErrorMetadataV10, ErrorMetadataV11, ErrorMetadataV12, ErrorMetadataV13, ErrorMetadataV14, ErrorMetadataV9, EventMetadataLatest, EventMetadataV10, EventMetadataV11, EventMetadataV12, EventMetadataV13, EventMetadataV14, EventMetadataV9, ExtrinsicMetadataLatest, ExtrinsicMetadataV11, ExtrinsicMetadataV12, ExtrinsicMetadataV13, ExtrinsicMetadataV14, FunctionArgumentMetadataLatest, FunctionArgumentMetadataV10, FunctionArgumentMetadataV11, FunctionArgumentMetadataV12, FunctionArgumentMetadataV13, FunctionArgumentMetadataV14, FunctionArgumentMetadataV9, FunctionMetadataLatest, FunctionMetadataV10, FunctionMetadataV11, FunctionMetadataV12, FunctionMetadataV13, FunctionMetadataV14, FunctionMetadataV9, MetadataAll, MetadataLatest, MetadataV10, MetadataV11, MetadataV12, MetadataV13, MetadataV14, MetadataV9, ModuleConstantMetadataV10, ModuleConstantMetadataV11, ModuleConstantMetadataV12, ModuleConstantMetadataV13, ModuleConstantMetadataV9, ModuleMetadataV10, ModuleMetadataV11, ModuleMetadataV12, ModuleMetadataV13, ModuleMetadataV9, PalletCallMetadataLatest, PalletCallMetadataV14, PalletConstantMetadataLatest, PalletConstantMetadataV14, PalletErrorMetadataLatest, PalletErrorMetadataV14, PalletEventMetadataLatest, PalletEventMetadataV14, PalletMetadataLatest, PalletMetadataV14, PalletStorageMetadataLatest, PalletStorageMetadataV14, PortableRegistry, PortableRegistryV14, PortableType, PortableTypeV14, SignedExtensionMetadataLatest, SignedExtensionMetadataV14, StorageEntryMetadataLatest, StorageEntryMetadataV10, StorageEntryMetadataV11, StorageEntryMetadataV12, StorageEntryMetadataV13, StorageEntryMetadataV14, StorageEntryMetadataV9, StorageEntryModifierLatest, StorageEntryModifierV10, StorageEntryModifierV11, StorageEntryModifierV12, StorageEntryModifierV13, StorageEntryModifierV14, StorageEntryModifierV9, StorageEntryTypeLatest, StorageEntryTypeV10, StorageEntryTypeV11, StorageEntryTypeV12, StorageEntryTypeV13, StorageEntryTypeV14, StorageEntryTypeV9, StorageHasher, StorageHasherV10, StorageHasherV11, StorageHasherV12, StorageHasherV13, StorageHasherV14, StorageHasherV9, StorageMetadataV10, StorageMetadataV11, StorageMetadataV12, StorageMetadataV13, StorageMetadataV9 } from '@polkadot/types/interfaces/metadata';
|
||||
import type { MmrLeafProof } from '@polkadot/types/interfaces/mmr';
|
||||
import type { StorageKind } from '@polkadot/types/interfaces/offchain';
|
||||
import type { DeferredOffenceOf, Kind, OffenceDetails, Offender, OpaqueTimeSlot, ReportIdOf, Reporter } from '@polkadot/types/interfaces/offences';
|
||||
@@ -44,7 +44,7 @@ import type { AccountStatus, AccountValidity } from '@polkadot/types/interfaces/
|
||||
import type { ActiveRecovery, RecoveryConfig } from '@polkadot/types/interfaces/recovery';
|
||||
import type { RpcMethods } from '@polkadot/types/interfaces/rpc';
|
||||
import type { AccountId, AccountId20, AccountId32, AccountIdOf, AccountIndex, Address, AssetId, Balance, BalanceOf, Block, BlockNumber, BlockNumberFor, BlockNumberOf, Call, CallHash, CallHashOf, ChangesTrieConfiguration, ChangesTrieSignal, CodecHash, Consensus, ConsensusEngineId, Digest, DigestItem, EncodedJustification, ExtrinsicsWeight, Fixed128, Fixed64, FixedI128, FixedI64, FixedU128, FixedU64, H1024, H128, H160, H2048, H256, H32, H512, H64, Hash, Header, HeaderPartial, I32F32, Index, IndicesLookupSource, Justification, Justifications, KeyTypeId, KeyValue, LockIdentifier, LookupSource, LookupTarget, ModuleId, Moment, MultiAddress, MultiSigner, OpaqueCall, Origin, OriginCaller, PalletId, PalletVersion, PalletsOrigin, Pays, PerU16, Perbill, Percent, Permill, Perquintill, Phantom, PhantomData, PreRuntime, Releases, RuntimeDbWeight, Seal, SealV0, SignedBlock, SignedBlockWithJustification, SignedBlockWithJustifications, Slot, StorageData, StorageProof, TransactionInfo, TransactionPriority, TransactionStorageProof, U32F32, ValidatorId, ValidatorIdOf, Weight, WeightMultiplier } from '@polkadot/types/interfaces/runtime';
|
||||
import type { Si0Field, Si0LookupTypeId, Si0Path, Si0Type, Si0TypeDef, Si0TypeDefArray, Si0TypeDefBitSequence, Si0TypeDefCompact, Si0TypeDefComposite, Si0TypeDefPhantom, Si0TypeDefPrimitive, Si0TypeDefSequence, Si0TypeDefTuple, Si0TypeDefVariant, Si0TypeParameter, Si0Variant, SiField, SiLookupTypeId, SiPath, SiType, SiTypeDef, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefPrimitive, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '@polkadot/types/interfaces/scaleInfo';
|
||||
import type { Si0Field, Si0LookupTypeId, Si0Path, Si0Type, Si0TypeDef, Si0TypeDefArray, Si0TypeDefBitSequence, Si0TypeDefCompact, Si0TypeDefComposite, Si0TypeDefPhantom, Si0TypeDefPrimitive, Si0TypeDefSequence, Si0TypeDefTuple, Si0TypeDefVariant, Si0TypeParameter, Si0Variant, Si1Field, Si1LookupTypeId, Si1Path, Si1Type, Si1TypeDef, Si1TypeDefArray, Si1TypeDefBitSequence, Si1TypeDefCompact, Si1TypeDefComposite, Si1TypeDefPrimitive, Si1TypeDefSequence, Si1TypeDefTuple, Si1TypeDefVariant, Si1TypeParameter, Si1Variant, SiField, SiLookupTypeId, SiPath, SiType, SiTypeDef, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefPrimitive, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '@polkadot/types/interfaces/scaleInfo';
|
||||
import type { Period, Priority, SchedulePeriod, SchedulePriority, Scheduled, ScheduledTo254, TaskAddress } from '@polkadot/types/interfaces/scheduler';
|
||||
import type { BeefyKey, FullIdentification, IdentificationTuple, Keys, MembershipProof, SessionIndex, SessionKeys1, SessionKeys10, SessionKeys10B, SessionKeys2, SessionKeys3, SessionKeys4, SessionKeys5, SessionKeys6, SessionKeys6B, SessionKeys7, SessionKeys7B, SessionKeys8, SessionKeys8B, SessionKeys9, SessionKeys9B, ValidatorCount } from '@polkadot/types/interfaces/session';
|
||||
import type { Bid, BidKind, SocietyJudgement, SocietyVote, StrikeCount, VouchingStatus } from '@polkadot/types/interfaces/society';
|
||||
@@ -676,7 +676,9 @@ declare module '@polkadot/types/types/registry' {
|
||||
PhragmenScore: PhragmenScore;
|
||||
Points: Points;
|
||||
PortableRegistry: PortableRegistry;
|
||||
PortableRegistryV14: PortableRegistryV14;
|
||||
PortableType: PortableType;
|
||||
PortableTypeV14: PortableTypeV14;
|
||||
Precommits: Precommits;
|
||||
PrefabWasmModule: PrefabWasmModule;
|
||||
PrefixedStorageKey: PrefixedStorageKey;
|
||||
@@ -813,6 +815,21 @@ declare module '@polkadot/types/types/registry' {
|
||||
Si0TypeDefVariant: Si0TypeDefVariant;
|
||||
Si0TypeParameter: Si0TypeParameter;
|
||||
Si0Variant: Si0Variant;
|
||||
Si1Field: Si1Field;
|
||||
Si1LookupTypeId: Si1LookupTypeId;
|
||||
Si1Path: Si1Path;
|
||||
Si1Type: Si1Type;
|
||||
Si1TypeDef: Si1TypeDef;
|
||||
Si1TypeDefArray: Si1TypeDefArray;
|
||||
Si1TypeDefBitSequence: Si1TypeDefBitSequence;
|
||||
Si1TypeDefCompact: Si1TypeDefCompact;
|
||||
Si1TypeDefComposite: Si1TypeDefComposite;
|
||||
Si1TypeDefPrimitive: Si1TypeDefPrimitive;
|
||||
Si1TypeDefSequence: Si1TypeDefSequence;
|
||||
Si1TypeDefTuple: Si1TypeDefTuple;
|
||||
Si1TypeDefVariant: Si1TypeDefVariant;
|
||||
Si1TypeParameter: Si1TypeParameter;
|
||||
Si1Variant: Si1Variant;
|
||||
SiField: SiField;
|
||||
Signature: Signature;
|
||||
SignedAvailabilityBitfield: SignedAvailabilityBitfield;
|
||||
|
||||
+9
-10
@@ -1,19 +1,18 @@
|
||||
// Copyright 2017-2021 @polkadot/types authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
import type { Vec } from '../codec/Vec';
|
||||
import type { PortableType } from '../interfaces/metadata';
|
||||
import type { SiField, SiLookupTypeId, SiPath, SiType, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '../interfaces/scaleInfo';
|
||||
import type { Text } from '../primitive/Text';
|
||||
import type { Type } from '../primitive/Type';
|
||||
import type { Registry, TypeDef } from '../types';
|
||||
import type { Vec } from '../../codec';
|
||||
import type { PortableType } from '../../interfaces/metadata';
|
||||
import type { SiField, SiLookupTypeId, SiPath, SiType, SiTypeDefArray, SiTypeDefBitSequence, SiTypeDefCompact, SiTypeDefComposite, SiTypeDefSequence, SiTypeDefTuple, SiTypeDefVariant, SiTypeParameter, SiVariant } from '../../interfaces/scaleInfo';
|
||||
import type { Text, Type } from '../../primitive';
|
||||
import type { Registry, TypeDef } from '../../types';
|
||||
|
||||
import { assert, isNumber, isString, stringCamelCase, stringify, stringUpperFirst } from '@polkadot/util';
|
||||
|
||||
import { Struct } from '../codec/Struct';
|
||||
import { withTypeString } from '../create/encodeTypes';
|
||||
import { getTypeDef } from '../create/getTypeDef';
|
||||
import { TypeDefInfo } from '../types';
|
||||
import { Struct } from '../../codec/Struct';
|
||||
import { withTypeString } from '../../create/encodeTypes';
|
||||
import { getTypeDef } from '../../create/getTypeDef';
|
||||
import { TypeDefInfo } from '../../types';
|
||||
|
||||
// Just a placeholder for a type.unrwapOr()
|
||||
const TYPE_UNWRAP = { toNumber: () => -1 };
|
||||
@@ -0,0 +1,5 @@
|
||||
// Copyright 2017-2021 @polkadot/types authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
export { GenericPortableRegistry } from './PortableRegistry';
|
||||
export { toV1 as convertSiV0toV1 } from './toV1';
|
||||
@@ -0,0 +1,133 @@
|
||||
// Copyright 2017-2021 @polkadot/types authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
import type { PortableType, Si0Field, Si0LookupTypeId, Si0Path, Si0Type, Si0TypeDefArray, Si0TypeDefBitSequence, Si0TypeDefComposite, Si0TypeDefPrimitive, Si0TypeDefSequence, Si0TypeDefVariant, Si1Field, Si1TypeDef } from '../../interfaces';
|
||||
import type { Registry } from '../../types';
|
||||
|
||||
function convertArray (registry: Registry, { len, type }: Si0TypeDefArray): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Array: {
|
||||
len,
|
||||
type: type.toNumber()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertBitSequence (registry: Registry, { bitOrderType, bitStoreType }: Si0TypeDefBitSequence): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
BitSequence: {
|
||||
bitOrderType: bitOrderType.toNumber(),
|
||||
bitStoreType: bitStoreType.toNumber()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertCompact (registry: Registry, { type }: Si0TypeDefSequence): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Compact: {
|
||||
type: type.toNumber()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertComposite (registry: Registry, { fields }: Si0TypeDefComposite): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Composite: {
|
||||
fields: convertFields(registry, fields)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertFields (registry: Registry, fields: Si0Field[]): Si1Field[] {
|
||||
return fields.map(({ docs, name, type, typeName }) =>
|
||||
registry.createType('Si1Field', {
|
||||
docs,
|
||||
name,
|
||||
type: type.toNumber(),
|
||||
typeName
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
function convertPhantom (registry: Registry, path: Si0Path): Si1TypeDef {
|
||||
console.warn(`Converting phantom type ${path.map((p) => p.toString()).join('::')} to empty tuple`);
|
||||
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Tuple: []
|
||||
});
|
||||
}
|
||||
|
||||
function convertPrimitive (registry: Registry, prim: Si0TypeDefPrimitive): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Primitive: prim.toString()
|
||||
});
|
||||
}
|
||||
|
||||
function convertSequence (registry: Registry, { type }: Si0TypeDefSequence): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Sequence: {
|
||||
type: type.toNumber()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertTuple (registry: Registry, types: Si0LookupTypeId[]): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Tuple: types.map((t) => t.toNumber())
|
||||
});
|
||||
}
|
||||
|
||||
function convertVariant (registry: Registry, { variants }: Si0TypeDefVariant): Si1TypeDef {
|
||||
return registry.createType('Si1TypeDef', {
|
||||
Variant: {
|
||||
variants: variants.map(({ discriminant, docs, fields, name }, index) =>
|
||||
registry.createType('Si1Variant', {
|
||||
docs,
|
||||
fields: convertFields(registry, fields),
|
||||
index: discriminant.isSome
|
||||
? discriminant.unwrap().toNumber()
|
||||
: index,
|
||||
name
|
||||
})
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function convertDef (registry: Registry, { def, path }: Si0Type): Si1TypeDef {
|
||||
if (def.isArray) {
|
||||
return convertArray(registry, def.asArray);
|
||||
} else if (def.isBitSequence) {
|
||||
return convertBitSequence(registry, def.asBitSequence);
|
||||
} else if (def.isCompact) {
|
||||
return convertCompact(registry, def.asCompact);
|
||||
} else if (def.isComposite) {
|
||||
return convertComposite(registry, def.asComposite);
|
||||
} else if (def.isPhantom) {
|
||||
return convertPhantom(registry, path);
|
||||
} else if (def.isPrimitive) {
|
||||
return convertPrimitive(registry, def.asPrimitive);
|
||||
} else if (def.isSequence) {
|
||||
return convertSequence(registry, def.asSequence);
|
||||
} else if (def.isTuple) {
|
||||
return convertTuple(registry, def.asTuple);
|
||||
} else if (def.isVariant) {
|
||||
return convertVariant(registry, def.asVariant);
|
||||
}
|
||||
|
||||
throw new Error(`Cannot convert type ${def.toString()}`);
|
||||
}
|
||||
|
||||
export function toV1 (registry: Registry, types: Si0Type[]): PortableType[] {
|
||||
return types.map((t, id) =>
|
||||
registry.createType('PortableType', {
|
||||
id,
|
||||
type: {
|
||||
def: convertDef(registry, t),
|
||||
docs: [],
|
||||
params: t.params.map((p) => p.toNumber()),
|
||||
path: t.path.map((p) => p.toString())
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
@@ -66,9 +66,9 @@ export default {
|
||||
_enum: ['Normal', 'RejectingOutboundMessages', 'Halted']
|
||||
},
|
||||
OutboundLaneData: {
|
||||
latestGeneratedNonce: 'MessageNonce',
|
||||
oldestUnprunedNonce: 'MessageNonce',
|
||||
latestReceivedNonce: 'MessageNonce',
|
||||
oldestUnprunedNonce: 'MessageNonce'
|
||||
latestGeneratedNonce: 'MessageNonce'
|
||||
},
|
||||
OutboundMessageFee: 'Balance',
|
||||
OutboundPayload: {
|
||||
|
||||
@@ -102,9 +102,9 @@ export interface OperatingMode extends Enum {
|
||||
|
||||
/** @name OutboundLaneData */
|
||||
export interface OutboundLaneData extends Struct {
|
||||
readonly latestGeneratedNonce: MessageNonce;
|
||||
readonly latestReceivedNonce: MessageNonce;
|
||||
readonly oldestUnprunedNonce: MessageNonce;
|
||||
readonly latestReceivedNonce: MessageNonce;
|
||||
readonly latestGeneratedNonce: MessageNonce;
|
||||
}
|
||||
|
||||
/** @name OutboundMessageFee */
|
||||
|
||||
@@ -78,6 +78,26 @@ export default {
|
||||
],
|
||||
type: 'Option<StorageData>'
|
||||
},
|
||||
getStorageEntries: {
|
||||
description: 'Returns child storage entries for multiple keys at a specific block state',
|
||||
params: [
|
||||
{
|
||||
name: 'childKey',
|
||||
type: 'PrefixedStorageKey'
|
||||
},
|
||||
{
|
||||
name: 'keys',
|
||||
type: 'Vec<StorageKey>'
|
||||
},
|
||||
{
|
||||
name: 'at',
|
||||
type: 'Hash',
|
||||
isHistoric: true,
|
||||
isOptional: true
|
||||
}
|
||||
],
|
||||
type: 'Vec<Option<StorageData>>'
|
||||
},
|
||||
getStorageHash: {
|
||||
description: 'Returns the hash of a child storage entry at a block state',
|
||||
params: [
|
||||
|
||||
@@ -26,6 +26,10 @@ export default {
|
||||
...v13,
|
||||
...v14,
|
||||
|
||||
// registry mapping to latest
|
||||
PortableRegistry: 'PortableRegistryV14',
|
||||
PortableType: 'PortableTypeV14',
|
||||
|
||||
// latest mappings
|
||||
ErrorMetadataLatest: 'ErrorMetadataV14',
|
||||
EventMetadataLatest: 'EventMetadataV14',
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
/* eslint-disable */
|
||||
|
||||
import type { Bytes, Enum, GenericPortableRegistry, Option, Struct, Text, Type, Vec, bool, u8 } from '@polkadot/types';
|
||||
import type { SiField, SiLookupTypeId, SiType } from '@polkadot/types/interfaces/scaleInfo';
|
||||
import type { Si1Field, Si1LookupTypeId, Si1Type, SiLookupTypeId } from '@polkadot/types/interfaces/scaleInfo';
|
||||
|
||||
/** @name ErrorMetadataLatest */
|
||||
export interface ErrorMetadataLatest extends ErrorMetadataV14 {}
|
||||
@@ -22,7 +22,7 @@ export interface ErrorMetadataV13 extends ErrorMetadataV12 {}
|
||||
/** @name ErrorMetadataV14 */
|
||||
export interface ErrorMetadataV14 extends Struct {
|
||||
readonly name: Text;
|
||||
readonly fields: Vec<SiField>;
|
||||
readonly fields: Vec<Si1Field>;
|
||||
readonly index: u8;
|
||||
readonly docs: Vec<Text>;
|
||||
readonly args: Vec<Type>;
|
||||
@@ -52,7 +52,7 @@ export interface EventMetadataV13 extends EventMetadataV12 {}
|
||||
/** @name EventMetadataV14 */
|
||||
export interface EventMetadataV14 extends Struct {
|
||||
readonly name: Text;
|
||||
readonly fields: Vec<SiField>;
|
||||
readonly fields: Vec<Si1Field>;
|
||||
readonly index: u8;
|
||||
readonly docs: Vec<Text>;
|
||||
readonly args: Vec<Type>;
|
||||
@@ -129,7 +129,7 @@ export interface FunctionMetadataV13 extends FunctionMetadataV12 {}
|
||||
/** @name FunctionMetadataV14 */
|
||||
export interface FunctionMetadataV14 extends Struct {
|
||||
readonly name: Text;
|
||||
readonly fields: Vec<SiField>;
|
||||
readonly fields: Vec<Si1Field>;
|
||||
readonly index: u8;
|
||||
readonly docs: Vec<Text>;
|
||||
readonly args: Vec<FunctionArgumentMetadataV14>;
|
||||
@@ -327,12 +327,18 @@ export interface PalletStorageMetadataV14 extends Struct {
|
||||
}
|
||||
|
||||
/** @name PortableRegistry */
|
||||
export interface PortableRegistry extends GenericPortableRegistry {}
|
||||
export interface PortableRegistry extends PortableRegistryV14 {}
|
||||
|
||||
/** @name PortableRegistryV14 */
|
||||
export interface PortableRegistryV14 extends GenericPortableRegistry {}
|
||||
|
||||
/** @name PortableType */
|
||||
export interface PortableType extends Struct {
|
||||
readonly id: SiLookupTypeId;
|
||||
readonly type: SiType;
|
||||
export interface PortableType extends PortableTypeV14 {}
|
||||
|
||||
/** @name PortableTypeV14 */
|
||||
export interface PortableTypeV14 extends Struct {
|
||||
readonly id: Si1LookupTypeId;
|
||||
readonly type: Si1Type;
|
||||
}
|
||||
|
||||
/** @name SignedExtensionMetadataLatest */
|
||||
|
||||
@@ -6,28 +6,28 @@
|
||||
|
||||
import type { DefinitionsTypes } from '../../types';
|
||||
|
||||
import { SiVariant } from '../scaleInfo/definitions';
|
||||
import { Si1Variant } from '../scaleInfo/v1';
|
||||
|
||||
export const v14: DefinitionsTypes = {
|
||||
// registry
|
||||
PortableRegistry: 'GenericPortableRegistry',
|
||||
PortableType: {
|
||||
id: 'SiLookupTypeId',
|
||||
type: 'SiType'
|
||||
PortableRegistryV14: 'GenericPortableRegistry',
|
||||
PortableTypeV14: {
|
||||
id: 'Si1LookupTypeId',
|
||||
type: 'Si1Type'
|
||||
},
|
||||
|
||||
// compatibility with earlier layouts, i.e. don't break previous users
|
||||
ErrorMetadataV14: {
|
||||
...SiVariant,
|
||||
...Si1Variant,
|
||||
args: 'Vec<Type>'
|
||||
},
|
||||
EventMetadataV14: {
|
||||
...SiVariant,
|
||||
...Si1Variant,
|
||||
args: 'Vec<Type>'
|
||||
},
|
||||
FunctionArgumentMetadataV14: 'FunctionArgumentMetadataV13',
|
||||
FunctionMetadataV14: {
|
||||
...SiVariant,
|
||||
...Si1Variant,
|
||||
args: 'Vec<FunctionArgumentMetadataV14>'
|
||||
},
|
||||
|
||||
|
||||
@@ -4,78 +4,32 @@
|
||||
import type { Definitions } from '../../types';
|
||||
|
||||
import { v0 } from './v0';
|
||||
import { v1 } from './v1';
|
||||
|
||||
// order important in structs... :)
|
||||
/* eslint-disable sort-keys */
|
||||
|
||||
export const SiVariant = {
|
||||
name: 'Text',
|
||||
fields: 'Vec<SiField>',
|
||||
index: 'u8',
|
||||
docs: 'Vec<Text>'
|
||||
};
|
||||
|
||||
export default {
|
||||
rpc: {},
|
||||
types: {
|
||||
...v0,
|
||||
SiField: {
|
||||
name: 'Option<Text>',
|
||||
type: 'SiLookupTypeId',
|
||||
typeName: 'Option<Text>',
|
||||
docs: 'Vec<Text>'
|
||||
},
|
||||
SiLookupTypeId: 'Compact<u32>',
|
||||
SiPath: 'Vec<Text>',
|
||||
SiType: {
|
||||
path: 'SiPath',
|
||||
params: 'Vec<SiTypeParameter>',
|
||||
def: 'SiTypeDef',
|
||||
docs: 'Vec<Text>'
|
||||
},
|
||||
SiTypeDef: {
|
||||
_enum: {
|
||||
Composite: 'SiTypeDefComposite',
|
||||
Variant: 'SiTypeDefVariant',
|
||||
Sequence: 'SiTypeDefSequence',
|
||||
Array: 'SiTypeDefArray',
|
||||
Tuple: 'SiTypeDefTuple',
|
||||
Primitive: 'SiTypeDefPrimitive',
|
||||
Compact: 'SiTypeDefCompact',
|
||||
BitSequence: 'SiTypeDefBitSequence',
|
||||
// NOTE: This is specific to the implementation for pre-v14 metadata
|
||||
// compatibility (always keep this as the last entry in the enum)
|
||||
HistoricMetaCompat: 'Type'
|
||||
}
|
||||
},
|
||||
SiTypeDefArray: {
|
||||
len: 'u32',
|
||||
type: 'SiLookupTypeId'
|
||||
},
|
||||
SiTypeDefBitSequence: {
|
||||
bitStoreType: 'SiLookupTypeId',
|
||||
bitOrderType: 'SiLookupTypeId'
|
||||
},
|
||||
SiTypeDefCompact: {
|
||||
type: 'SiLookupTypeId'
|
||||
},
|
||||
SiTypeDefComposite: {
|
||||
fields: 'Vec<SiField>'
|
||||
},
|
||||
SiTypeDefPrimitive: {
|
||||
_enum: ['Bool', 'Char', 'Str', 'U8', 'U16', 'U32', 'U64', 'U128', 'U256', 'I8', 'I16', 'I32', 'I64', 'I128', 'I256']
|
||||
},
|
||||
SiTypeDefSequence: {
|
||||
type: 'SiLookupTypeId'
|
||||
},
|
||||
SiTypeDefTuple: 'Vec<SiLookupTypeId>',
|
||||
SiTypeParameter: {
|
||||
name: 'Text',
|
||||
type: 'Option<SiLookupTypeId>'
|
||||
},
|
||||
SiTypeDefVariant: {
|
||||
variants: 'Vec<SiVariant>'
|
||||
},
|
||||
SiVariant
|
||||
...v1,
|
||||
|
||||
// latest mappings
|
||||
SiField: 'Si1Field',
|
||||
SiLookupTypeId: 'Si1LookupTypeId',
|
||||
SiPath: 'Si1Path',
|
||||
SiType: 'Si1Type',
|
||||
SiTypeDef: 'Si1TypeDef',
|
||||
SiTypeDefArray: 'Si1TypeDefArray',
|
||||
SiTypeDefBitSequence: 'Si1TypeDefBitSequence',
|
||||
SiTypeDefCompact: 'Si1TypeDefCompact',
|
||||
SiTypeDefComposite: 'Si1TypeDefComposite',
|
||||
SiTypeDefPrimitive: 'Si1TypeDefPrimitive',
|
||||
SiTypeDefSequence: 'Si1TypeDefSequence',
|
||||
SiTypeDefTuple: 'Si1TypeDefTuple',
|
||||
SiTypeParameter: 'Si1TypeParameter',
|
||||
SiTypeDefVariant: 'Si1TypeDefVariant',
|
||||
SiVariant: 'Si1Variant'
|
||||
}
|
||||
} as Definitions;
|
||||
|
||||
@@ -118,116 +118,145 @@ export interface Si0Variant extends Struct {
|
||||
readonly docs: Vec<Text>;
|
||||
}
|
||||
|
||||
/** @name SiField */
|
||||
export interface SiField extends Struct {
|
||||
/** @name Si1Field */
|
||||
export interface Si1Field extends Struct {
|
||||
readonly name: Option<Text>;
|
||||
readonly type: SiLookupTypeId;
|
||||
readonly type: Si1LookupTypeId;
|
||||
readonly typeName: Option<Text>;
|
||||
readonly docs: Vec<Text>;
|
||||
}
|
||||
|
||||
/** @name SiLookupTypeId */
|
||||
export interface SiLookupTypeId extends Compact<u32> {}
|
||||
/** @name Si1LookupTypeId */
|
||||
export interface Si1LookupTypeId extends Compact<u32> {}
|
||||
|
||||
/** @name SiPath */
|
||||
export interface SiPath extends Vec<Text> {}
|
||||
/** @name Si1Path */
|
||||
export interface Si1Path extends Si0Path {}
|
||||
|
||||
/** @name SiType */
|
||||
export interface SiType extends Struct {
|
||||
readonly path: SiPath;
|
||||
readonly params: Vec<SiTypeParameter>;
|
||||
readonly def: SiTypeDef;
|
||||
/** @name Si1Type */
|
||||
export interface Si1Type extends Struct {
|
||||
readonly path: Si1Path;
|
||||
readonly params: Vec<Si1TypeParameter>;
|
||||
readonly def: Si1TypeDef;
|
||||
readonly docs: Vec<Text>;
|
||||
}
|
||||
|
||||
/** @name SiTypeDef */
|
||||
export interface SiTypeDef extends Enum {
|
||||
/** @name Si1TypeDef */
|
||||
export interface Si1TypeDef extends Enum {
|
||||
readonly isComposite: boolean;
|
||||
readonly asComposite: SiTypeDefComposite;
|
||||
readonly asComposite: Si1TypeDefComposite;
|
||||
readonly isVariant: boolean;
|
||||
readonly asVariant: SiTypeDefVariant;
|
||||
readonly asVariant: Si1TypeDefVariant;
|
||||
readonly isSequence: boolean;
|
||||
readonly asSequence: SiTypeDefSequence;
|
||||
readonly asSequence: Si1TypeDefSequence;
|
||||
readonly isArray: boolean;
|
||||
readonly asArray: SiTypeDefArray;
|
||||
readonly asArray: Si1TypeDefArray;
|
||||
readonly isTuple: boolean;
|
||||
readonly asTuple: SiTypeDefTuple;
|
||||
readonly asTuple: Si1TypeDefTuple;
|
||||
readonly isPrimitive: boolean;
|
||||
readonly asPrimitive: SiTypeDefPrimitive;
|
||||
readonly asPrimitive: Si1TypeDefPrimitive;
|
||||
readonly isCompact: boolean;
|
||||
readonly asCompact: SiTypeDefCompact;
|
||||
readonly asCompact: Si1TypeDefCompact;
|
||||
readonly isBitSequence: boolean;
|
||||
readonly asBitSequence: SiTypeDefBitSequence;
|
||||
readonly asBitSequence: Si1TypeDefBitSequence;
|
||||
readonly isHistoricMetaCompat: boolean;
|
||||
readonly asHistoricMetaCompat: Type;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefArray */
|
||||
export interface SiTypeDefArray extends Struct {
|
||||
/** @name Si1TypeDefArray */
|
||||
export interface Si1TypeDefArray extends Struct {
|
||||
readonly len: u32;
|
||||
readonly type: SiLookupTypeId;
|
||||
readonly type: Si1LookupTypeId;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefBitSequence */
|
||||
export interface SiTypeDefBitSequence extends Struct {
|
||||
readonly bitStoreType: SiLookupTypeId;
|
||||
readonly bitOrderType: SiLookupTypeId;
|
||||
/** @name Si1TypeDefBitSequence */
|
||||
export interface Si1TypeDefBitSequence extends Struct {
|
||||
readonly bitStoreType: Si1LookupTypeId;
|
||||
readonly bitOrderType: Si1LookupTypeId;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefCompact */
|
||||
export interface SiTypeDefCompact extends Struct {
|
||||
readonly type: SiLookupTypeId;
|
||||
/** @name Si1TypeDefCompact */
|
||||
export interface Si1TypeDefCompact extends Struct {
|
||||
readonly type: Si1LookupTypeId;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefComposite */
|
||||
export interface SiTypeDefComposite extends Struct {
|
||||
readonly fields: Vec<SiField>;
|
||||
/** @name Si1TypeDefComposite */
|
||||
export interface Si1TypeDefComposite extends Struct {
|
||||
readonly fields: Vec<Si1Field>;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefPrimitive */
|
||||
export interface SiTypeDefPrimitive extends Enum {
|
||||
readonly isBool: boolean;
|
||||
readonly isChar: boolean;
|
||||
readonly isStr: boolean;
|
||||
readonly isU8: boolean;
|
||||
readonly isU16: boolean;
|
||||
readonly isU32: boolean;
|
||||
readonly isU64: boolean;
|
||||
readonly isU128: boolean;
|
||||
readonly isU256: boolean;
|
||||
readonly isI8: boolean;
|
||||
readonly isI16: boolean;
|
||||
readonly isI32: boolean;
|
||||
readonly isI64: boolean;
|
||||
readonly isI128: boolean;
|
||||
readonly isI256: boolean;
|
||||
/** @name Si1TypeDefPrimitive */
|
||||
export interface Si1TypeDefPrimitive extends Si0TypeDefPrimitive {}
|
||||
|
||||
/** @name Si1TypeDefSequence */
|
||||
export interface Si1TypeDefSequence extends Struct {
|
||||
readonly type: Si1LookupTypeId;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefSequence */
|
||||
export interface SiTypeDefSequence extends Struct {
|
||||
readonly type: SiLookupTypeId;
|
||||
/** @name Si1TypeDefTuple */
|
||||
export interface Si1TypeDefTuple extends Vec<Si1LookupTypeId> {}
|
||||
|
||||
/** @name Si1TypeDefVariant */
|
||||
export interface Si1TypeDefVariant extends Struct {
|
||||
readonly variants: Vec<Si1Variant>;
|
||||
}
|
||||
|
||||
/** @name SiTypeDefTuple */
|
||||
export interface SiTypeDefTuple extends Vec<SiLookupTypeId> {}
|
||||
|
||||
/** @name SiTypeDefVariant */
|
||||
export interface SiTypeDefVariant extends Struct {
|
||||
readonly variants: Vec<SiVariant>;
|
||||
}
|
||||
|
||||
/** @name SiTypeParameter */
|
||||
export interface SiTypeParameter extends Struct {
|
||||
/** @name Si1TypeParameter */
|
||||
export interface Si1TypeParameter extends Struct {
|
||||
readonly name: Text;
|
||||
readonly type: Option<SiLookupTypeId>;
|
||||
readonly type: Option<Si1LookupTypeId>;
|
||||
}
|
||||
|
||||
/** @name SiVariant */
|
||||
export interface SiVariant extends Struct {
|
||||
/** @name Si1Variant */
|
||||
export interface Si1Variant extends Struct {
|
||||
readonly name: Text;
|
||||
readonly fields: Vec<SiField>;
|
||||
readonly fields: Vec<Si1Field>;
|
||||
readonly index: u8;
|
||||
readonly docs: Vec<Text>;
|
||||
}
|
||||
|
||||
/** @name SiField */
|
||||
export interface SiField extends Si1Field {}
|
||||
|
||||
/** @name SiLookupTypeId */
|
||||
export interface SiLookupTypeId extends Si1LookupTypeId {}
|
||||
|
||||
/** @name SiPath */
|
||||
export interface SiPath extends Si1Path {}
|
||||
|
||||
/** @name SiType */
|
||||
export interface SiType extends Si1Type {}
|
||||
|
||||
/** @name SiTypeDef */
|
||||
export interface SiTypeDef extends Si1TypeDef {}
|
||||
|
||||
/** @name SiTypeDefArray */
|
||||
export interface SiTypeDefArray extends Si1TypeDefArray {}
|
||||
|
||||
/** @name SiTypeDefBitSequence */
|
||||
export interface SiTypeDefBitSequence extends Si1TypeDefBitSequence {}
|
||||
|
||||
/** @name SiTypeDefCompact */
|
||||
export interface SiTypeDefCompact extends Si1TypeDefCompact {}
|
||||
|
||||
/** @name SiTypeDefComposite */
|
||||
export interface SiTypeDefComposite extends Si1TypeDefComposite {}
|
||||
|
||||
/** @name SiTypeDefPrimitive */
|
||||
export interface SiTypeDefPrimitive extends Si1TypeDefPrimitive {}
|
||||
|
||||
/** @name SiTypeDefSequence */
|
||||
export interface SiTypeDefSequence extends Si1TypeDefSequence {}
|
||||
|
||||
/** @name SiTypeDefTuple */
|
||||
export interface SiTypeDefTuple extends Si1TypeDefTuple {}
|
||||
|
||||
/** @name SiTypeDefVariant */
|
||||
export interface SiTypeDefVariant extends Si1TypeDefVariant {}
|
||||
|
||||
/** @name SiTypeParameter */
|
||||
export interface SiTypeParameter extends Si1TypeParameter {}
|
||||
|
||||
/** @name SiVariant */
|
||||
export interface SiVariant extends Si1Variant {}
|
||||
|
||||
export type PHANTOM_SCALEINFO = 'scaleInfo';
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
// Copyright 2017-2021 @polkadot/types authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
import type { DefinitionsTypes } from '../../types';
|
||||
|
||||
// order important in structs... :)
|
||||
/* eslint-disable sort-keys */
|
||||
|
||||
export const Si1Variant = {
|
||||
name: 'Text',
|
||||
fields: 'Vec<Si1Field>',
|
||||
index: 'u8',
|
||||
docs: 'Vec<Text>'
|
||||
};
|
||||
|
||||
export const v1: DefinitionsTypes = {
|
||||
Si1Field: {
|
||||
name: 'Option<Text>',
|
||||
type: 'Si1LookupTypeId',
|
||||
typeName: 'Option<Text>',
|
||||
docs: 'Vec<Text>'
|
||||
},
|
||||
Si1LookupTypeId: 'Compact<u32>',
|
||||
Si1Path: 'Si0Path',
|
||||
Si1Type: {
|
||||
path: 'Si1Path',
|
||||
params: 'Vec<Si1TypeParameter>',
|
||||
def: 'Si1TypeDef',
|
||||
docs: 'Vec<Text>'
|
||||
},
|
||||
Si1TypeDef: {
|
||||
_enum: {
|
||||
Composite: 'Si1TypeDefComposite',
|
||||
Variant: 'Si1TypeDefVariant',
|
||||
Sequence: 'Si1TypeDefSequence',
|
||||
Array: 'Si1TypeDefArray',
|
||||
Tuple: 'Si1TypeDefTuple',
|
||||
Primitive: 'Si1TypeDefPrimitive',
|
||||
Compact: 'Si1TypeDefCompact',
|
||||
BitSequence: 'Si1TypeDefBitSequence',
|
||||
// NOTE: This is specific to the implementation for pre-v14 metadata
|
||||
// compatibility (always keep this as the last entry in the enum)
|
||||
HistoricMetaCompat: 'Type'
|
||||
}
|
||||
},
|
||||
Si1TypeDefArray: {
|
||||
len: 'u32',
|
||||
type: 'Si1LookupTypeId'
|
||||
},
|
||||
Si1TypeDefBitSequence: {
|
||||
bitStoreType: 'Si1LookupTypeId',
|
||||
bitOrderType: 'Si1LookupTypeId'
|
||||
},
|
||||
Si1TypeDefCompact: {
|
||||
type: 'Si1LookupTypeId'
|
||||
},
|
||||
Si1TypeDefComposite: {
|
||||
fields: 'Vec<Si1Field>'
|
||||
},
|
||||
Si1TypeDefPrimitive: 'Si0TypeDefPrimitive',
|
||||
Si1TypeDefSequence: {
|
||||
type: 'Si1LookupTypeId'
|
||||
},
|
||||
Si1TypeDefTuple: 'Vec<Si1LookupTypeId>',
|
||||
Si1TypeParameter: {
|
||||
name: 'Text',
|
||||
type: 'Option<Si1LookupTypeId>'
|
||||
},
|
||||
Si1TypeDefVariant: {
|
||||
variants: 'Vec<Si1Variant>'
|
||||
},
|
||||
Si1Variant
|
||||
};
|
||||
@@ -3,4 +3,4 @@
|
||||
|
||||
// Auto-generated by @polkadot/dev, do not edit
|
||||
|
||||
export const packageInfo = { name: '@polkadot/types', version: '6.0.5' };
|
||||
export const packageInfo = { name: '@polkadot/types', version: '6.1.1' };
|
||||
|
||||
Reference in New Issue
Block a user