Bump API (#5886)
This commit is contained in:
parent
bc59761bec
commit
5430223613
16
package.json
16
package.json
@ -12,15 +12,15 @@
|
||||
"packages/*"
|
||||
],
|
||||
"resolutions": {
|
||||
"@polkadot/api": "^5.1.2-7",
|
||||
"@polkadot/api-contract": "^5.1.2-7",
|
||||
"@polkadot/hw-ledger": "^7.0.3-0",
|
||||
"@polkadot/keyring": "^7.0.3-0",
|
||||
"@polkadot/networks": "^7.0.3-0",
|
||||
"@polkadot/api": "^5.2.2-4",
|
||||
"@polkadot/api-contract": "^5.2.2-4",
|
||||
"@polkadot/hw-ledger": "^7.0.3",
|
||||
"@polkadot/keyring": "^7.0.3",
|
||||
"@polkadot/networks": "^7.0.3",
|
||||
"@polkadot/phishing": "^0.6.234",
|
||||
"@polkadot/types": "^5.1.2-7",
|
||||
"@polkadot/util": "^7.0.3-0",
|
||||
"@polkadot/util-crypto": "^7.0.3-0",
|
||||
"@polkadot/types": "^5.2.2-4",
|
||||
"@polkadot/util": "^7.0.3",
|
||||
"@polkadot/util-crypto": "^7.0.3",
|
||||
"@polkadot/wasm-crypto": "^4.1.2",
|
||||
"babel-core": "^7.0.0-bridge.0",
|
||||
"styled-components": "^5.2.0",
|
||||
|
||||
@ -20,7 +20,7 @@
|
||||
"@kiltprotocol/type-definitions": "0.1.8",
|
||||
"@laminar/type-definitions": "0.3.1",
|
||||
"@phala/typedefs": "0.2.1",
|
||||
"@polkadot/networks": "^7.0.3-0",
|
||||
"@polkadot/networks": "^7.0.3",
|
||||
"@polymathnetwork/polymesh-types": "0.0.2",
|
||||
"@snowfork/snowbridge-types": "0.2.3",
|
||||
"@sora-substrate/type-definitions": "1.3.34",
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
"@babel/runtime": "^7.14.6",
|
||||
"@polkadot/phishing": "^0.6.234",
|
||||
"@polkadot/react-components": "^0.94.2-92",
|
||||
"@polkadot/vanitygen": "^0.42.1",
|
||||
"@polkadot/vanitygen": "^0.43.1",
|
||||
"detect-browser": "^5.2.0",
|
||||
"file-saver": "^2.0.5"
|
||||
},
|
||||
|
||||
@ -6,6 +6,6 @@
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.6",
|
||||
"@polkadot/api-contract": "^5.1.2-7"
|
||||
"@polkadot/api-contract": "^5.2.2-4"
|
||||
}
|
||||
}
|
||||
|
||||
@ -7,6 +7,7 @@ import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
|
||||
import { Icon, Tooltip } from '@polkadot/react-components';
|
||||
import { useApi } from '@polkadot/react-hooks';
|
||||
import { encodeTypeDef } from '@polkadot/types/create';
|
||||
|
||||
import { useTranslation } from '../translate';
|
||||
@ -29,6 +30,7 @@ function truncate (param: string): string {
|
||||
|
||||
function MessageSignature ({ className, message: { args, isConstructor, isMutating, method, returnType }, params = [], withTooltip = false }: Props): React.ReactElement<Props> {
|
||||
const { t } = useTranslation();
|
||||
const { api } = useApi();
|
||||
|
||||
return (
|
||||
<div className={className}>
|
||||
@ -41,7 +43,7 @@ function MessageSignature ({ className, message: { args, isConstructor, isMutati
|
||||
<span className='ui--MessageSignature-type'>
|
||||
{params && params[index]
|
||||
? <b>{truncate((params as string[])[index].toString())}</b>
|
||||
: encodeTypeDef(type)
|
||||
: encodeTypeDef(api.registry, type)
|
||||
}
|
||||
</span>
|
||||
{index < (args.length) - 1 && ', '}
|
||||
@ -53,7 +55,7 @@ function MessageSignature ({ className, message: { args, isConstructor, isMutati
|
||||
:
|
||||
{' '}
|
||||
<span className='ui--MessageSignature-returnType'>
|
||||
{encodeTypeDef(returnType)}
|
||||
{encodeTypeDef(api.registry, returnType)}
|
||||
</span>
|
||||
</>
|
||||
)}
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@babel/runtime": "^7.14.6",
|
||||
"@polkadot/api": "^5.1.2-7",
|
||||
"@polkadot/api": "^5.2.2-4",
|
||||
"@polkadot/extension-dapp": "^0.39.2-0",
|
||||
"@substrate/connect": "^0.3.16",
|
||||
"fflate": "^0.7.1",
|
||||
|
||||
@ -9,15 +9,15 @@
|
||||
"@fortawesome/fontawesome-svg-core": "^1.2.35",
|
||||
"@fortawesome/free-solid-svg-icons": "^5.15.3",
|
||||
"@fortawesome/react-fontawesome": "^0.1.14",
|
||||
"@polkadot/keyring": "^7.0.3-0",
|
||||
"@polkadot/keyring": "^7.0.3",
|
||||
"@polkadot/react-api": "^0.94.2-92",
|
||||
"@polkadot/react-identicon": "^0.84.1",
|
||||
"@polkadot/react-qr": "^0.84.1",
|
||||
"@polkadot/react-identicon": "^0.84.2",
|
||||
"@polkadot/react-qr": "^0.84.2",
|
||||
"@polkadot/react-query": "^0.94.2-92",
|
||||
"@polkadot/ui-keyring": "^0.84.1",
|
||||
"@polkadot/ui-settings": "^0.84.1",
|
||||
"@polkadot/util": "^7.0.3-0",
|
||||
"@polkadot/util-crypto": "^7.0.3-0",
|
||||
"@polkadot/ui-keyring": "^0.84.2",
|
||||
"@polkadot/ui-settings": "^0.84.2",
|
||||
"@polkadot/util": "^7.0.3",
|
||||
"@polkadot/util-crypto": "^7.0.3",
|
||||
"chart.js": "^2.9.4",
|
||||
"codeflask": "^1.4.1",
|
||||
"i18next": "^19.9.2",
|
||||
|
||||
@ -19,9 +19,9 @@ function Param ({ className = '', defaultValue, isDisabled, isInOption, isOption
|
||||
|
||||
const label = useMemo(
|
||||
() => isUndefined(name)
|
||||
? `${isDisabled && isInOption ? 'Option<' : ''}${encodeTypeDef(type)}${isDisabled && isInOption ? '>' : ''}`
|
||||
: `${name}: ${isDisabled && isInOption ? 'Option<' : ''}${encodeTypeDef(type)}${isDisabled && isInOption ? '>' : ''}`,
|
||||
[isDisabled, isInOption, name, type]
|
||||
? `${isDisabled && isInOption ? 'Option<' : ''}${encodeTypeDef(registry, type)}${isDisabled && isInOption ? '>' : ''}`
|
||||
: `${name}: ${isDisabled && isInOption ? 'Option<' : ''}${encodeTypeDef(registry, type)}${isDisabled && isInOption ? '>' : ''}`,
|
||||
[isDisabled, isInOption, name, registry, type]
|
||||
);
|
||||
|
||||
if (!Component) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user