diff --git a/package.json b/package.json index 46db9a99e4..7a1ae1fc8c 100644 --- a/package.json +++ b/package.json @@ -8,10 +8,10 @@ "packages/*" ], "resolutions": { - "@polkadot/api": "^1.9.0-beta.1", - "@polkadot/api-contract": "^1.9.0-beta.1", + "@polkadot/api": "^1.9.0-beta.6", + "@polkadot/api-contract": "^1.9.0-beta.6", "@polkadot/keyring": "^2.7.0-beta.8", - "@polkadot/types": "^1.9.0-beta.1", + "@polkadot/types": "^1.9.0-beta.6", "@polkadot/util": "^2.7.0-beta.8", "@polkadot/util-crypto": "^2.7.0-beta.8", "babel-core": "^7.0.0-bridge.0", diff --git a/packages/apps-routing/src/transfer.ts b/packages/apps-routing/src/transfer.ts index f53950b044..613a4f110a 100644 --- a/packages/apps-routing/src/transfer.ts +++ b/packages/apps-routing/src/transfer.ts @@ -4,12 +4,11 @@ import { Routes } from './types'; -import Transfer from '@polkadot/app-transfer'; import TransferModal from '@polkadot/app-accounts/Accounts/modals/Transfer'; export default ([ { - Component: Transfer, + Component: TransferModal, Modal: TransferModal, display: { isHidden: false, diff --git a/packages/apps/public/locales/en/app-transfer.json b/packages/apps/public/locales/en/app-transfer.json deleted file mode 100644 index 0967ef424b..0000000000 --- a/packages/apps/public/locales/en/app-transfer.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/packages/apps/public/locales/zh/app-transfer.json b/packages/apps/public/locales/zh/app-transfer.json deleted file mode 100644 index 0967ef424b..0000000000 --- a/packages/apps/public/locales/zh/app-transfer.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/packages/page-123code/src/SummaryBar.tsx b/packages/page-123code/src/SummaryBar.tsx index d36100d325..cf29ffaee4 100644 --- a/packages/page-123code/src/SummaryBar.tsx +++ b/packages/page-123code/src/SummaryBar.tsx @@ -3,7 +3,6 @@ // of the Apache-2.0 license. See the LICENSE file for details. import { DeriveStakingValidators } from '@polkadot/api-derive/types'; -import { BareProps as Props } from '@polkadot/react-components/types'; import { Balance, BlockNumber } from '@polkadot/types/interfaces'; import React from 'react'; @@ -11,8 +10,7 @@ import { Bubble, IdentityIcon } from '@polkadot/react-components'; import { useApi, useCall } from '@polkadot/react-hooks'; import { formatBalance, formatNumber } from '@polkadot/util'; -// eslint-disable-next-line @typescript-eslint/no-unused-vars -export default function SummaryBar (props: Props): React.ReactElement { +function SummaryBar (): React.ReactElement { const { api, systemChain, systemName, systemVersion } = useApi(); const bestNumber = useCall(api.derive.chain.bestNumber, []); const bestNumberLag = useCall(api.derive.chain.bestNumberLag, []); @@ -48,3 +46,5 @@ export default function SummaryBar (props: Props): React.ReactElement { ); } + +export default React.memo(SummaryBar); diff --git a/packages/page-123code/src/Transfer.tsx b/packages/page-123code/src/Transfer.tsx index 7966334832..d36b4f05ea 100644 --- a/packages/page-123code/src/Transfer.tsx +++ b/packages/page-123code/src/Transfer.tsx @@ -12,7 +12,7 @@ interface Props { accountId?: string | null; } -export default function Transfer ({ accountId }: Props): React.ReactElement { +function Transfer ({ accountId }: Props): React.ReactElement { const [amount, setAmount] = useState(null); const [recipientId, setRecipientId] = useState(null); @@ -46,3 +46,5 @@ export default function Transfer ({ accountId }: Props): React.ReactElement ); } + +export default React.memo(Transfer); diff --git a/packages/page-123code/src/index.tsx b/packages/page-123code/src/index.tsx index 91e5ea1c07..4595accad7 100644 --- a/packages/page-123code/src/index.tsx +++ b/packages/page-123code/src/index.tsx @@ -14,7 +14,7 @@ import AccountSelector from './AccountSelector'; import SummaryBar from './SummaryBar'; import Transfer from './Transfer'; -export default function TemplateApp ({ className }: Props): React.ReactElement { +function TemplateApp ({ className }: Props): React.ReactElement { const [accountId, setAccountId] = useState(null); return ( @@ -27,3 +27,5 @@ export default function TemplateApp ({ className }: Props): React.ReactElement

); } + +export default React.memo(TemplateApp); diff --git a/packages/page-accounts/src/Accounts/modals/Backup.tsx b/packages/page-accounts/src/Accounts/modals/Backup.tsx index b82ebfd1fb..2457be5af4 100644 --- a/packages/page-accounts/src/Accounts/modals/Backup.tsx +++ b/packages/page-accounts/src/Accounts/modals/Backup.tsx @@ -25,7 +25,7 @@ interface ContentProps { password: string; } -export default function ({ address, onClose }: Props): React.ReactElement { +function Backup ({ address, onClose }: Props): React.ReactElement { const { t } = useTranslation(); const [password, setPassword] = useState(''); const [isPassTouched, setIsPassTouched] = useState(false); @@ -110,3 +110,5 @@ function Content ({ address, doBackup, isPassTouched, isPassValid, onChangePass, ); } + +export default React.memo(Backup); diff --git a/packages/page-accounts/src/Accounts/modals/CreateConfirmation.tsx b/packages/page-accounts/src/Accounts/modals/CreateConfirmation.tsx index 5e4fad30cb..0b4c9a447e 100644 --- a/packages/page-accounts/src/Accounts/modals/CreateConfirmation.tsx +++ b/packages/page-accounts/src/Accounts/modals/CreateConfirmation.tsx @@ -14,7 +14,7 @@ interface Props { onCommit: () => void; } -export default function CreateConfirmation ({ address, name, onClose, onCommit }: Props): React.ReactElement | null { +function CreateConfirmation ({ address, name, onClose, onCommit }: Props): React.ReactElement | null { const { t } = useTranslation(); return ( @@ -41,3 +41,5 @@ export default function CreateConfirmation ({ address, name, onClose, onCommit } ); } + +export default React.memo(CreateConfirmation); diff --git a/packages/page-accounts/src/Accounts/modals/Derive.tsx b/packages/page-accounts/src/Accounts/modals/Derive.tsx index 92e0202810..35514d6b21 100644 --- a/packages/page-accounts/src/Accounts/modals/Derive.tsx +++ b/packages/page-accounts/src/Accounts/modals/Derive.tsx @@ -67,7 +67,7 @@ function createAccount (source: KeyringPair, suri: string, name: string, passwor return status; } -export default function Derive ({ className, from, onClose }: Props): React.ReactElement { +function Derive ({ className, from, onClose }: Props): React.ReactElement { const { t } = useTranslation(); const { queueAction } = useContext(StatusContext); const [source] = useState(keyring.getPair(from)); @@ -235,3 +235,5 @@ export default function Derive ({ className, from, onClose }: Props): React.Reac ); } + +export default React.memo(Derive); diff --git a/packages/page-accounts/src/Accounts/modals/RecoverAccount.tsx b/packages/page-accounts/src/Accounts/modals/RecoverAccount.tsx index 1b1f106daa..0994273587 100644 --- a/packages/page-accounts/src/Accounts/modals/RecoverAccount.tsx +++ b/packages/page-accounts/src/Accounts/modals/RecoverAccount.tsx @@ -13,7 +13,7 @@ interface Props { onClose: () => void; } -export default function RecoverAccount ({ address, className, onClose }: Props): React.ReactElement { +function RecoverAccount ({ address, className, onClose }: Props): React.ReactElement { const { t } = useTranslation(); const [recover, setRecover] = useState(null); @@ -49,3 +49,5 @@ export default function RecoverAccount ({ address, className, onClose }: Props): ); } + +export default React.memo(RecoverAccount); diff --git a/packages/page-accounts/src/Accounts/modals/RecoverSetup.tsx b/packages/page-accounts/src/Accounts/modals/RecoverSetup.tsx index d829f78b81..ac3ef3c3f1 100644 --- a/packages/page-accounts/src/Accounts/modals/RecoverSetup.tsx +++ b/packages/page-accounts/src/Accounts/modals/RecoverSetup.tsx @@ -17,7 +17,7 @@ interface Props { const MAX_HELPERS = 16; -export default function RecoverSetup ({ address, className, onClose }: Props): React.ReactElement { +function RecoverSetup ({ address, className, onClose }: Props): React.ReactElement { const { t } = useTranslation(); const { allAccounts } = useAccounts(); const { allAddresses } = useAddresses(); @@ -84,3 +84,5 @@ export default function RecoverSetup ({ address, className, onClose }: Props): R ); } + +export default React.memo(RecoverSetup); diff --git a/packages/page-contracts/package.json b/packages/page-contracts/package.json index 6652f267d3..02142dbfd6 100644 --- a/packages/page-contracts/package.json +++ b/packages/page-contracts/package.json @@ -12,6 +12,6 @@ "license": "Apache-2.0", "dependencies": { "@babel/runtime": "^7.9.2", - "@polkadot/api-contract": "^1.9.0-beta.1" + "@polkadot/api-contract": "^1.9.0-beta.6" } } diff --git a/packages/page-contracts/src/Contracts/ValidateAddr.tsx b/packages/page-contracts/src/Contracts/ValidateAddr.tsx index b0065dac1d..0a6b104fb6 100644 --- a/packages/page-contracts/src/Contracts/ValidateAddr.tsx +++ b/packages/page-contracts/src/Contracts/ValidateAddr.tsx @@ -17,7 +17,7 @@ interface Props { onChange: (isValid: boolean) => void; } -export default function ValidateAddr ({ address, onChange }: Props): React.ReactElement | null { +function ValidateAddr ({ address, onChange }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const contractInfo = useCall>(api.query.contracts.contractInfoOf, [address]); @@ -54,3 +54,5 @@ export default function ValidateAddr ({ address, onChange }: Props): React.React ); } + +export default React.memo(ValidateAddr); diff --git a/packages/page-contracts/src/Contracts/index.tsx b/packages/page-contracts/src/Contracts/index.tsx index f020f7f5c1..c9195964ed 100644 --- a/packages/page-contracts/src/Contracts/index.tsx +++ b/packages/page-contracts/src/Contracts/index.tsx @@ -23,7 +23,7 @@ function filterContracts (api: ApiPromise, { accounts, contracts: keyringContrac .filter((contract: ApiContract | null): boolean => !!contract) as ApiContract[]; } -export default function Contracts (props: Props): React.ReactElement { +function Contracts (props: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const { accounts, basePath, contracts: keyringContracts, hasCode, showDeploy } = props; @@ -118,3 +118,5 @@ export default function Contracts (props: Props): React.ReactElement { ); } + +export default React.memo(Contracts); diff --git a/packages/page-contracts/src/MessageSignature.tsx b/packages/page-contracts/src/MessageSignature.tsx index e2d504bbc9..eecf89ca63 100644 --- a/packages/page-contracts/src/MessageSignature.tsx +++ b/packages/page-contracts/src/MessageSignature.tsx @@ -51,7 +51,7 @@ function truncate (param: string): string { : param; } -export default function MessageSignature ({ message: { args, mutates, name, returnType }, params = [], asConstructor = false, withTooltip = false }: Props): React.ReactElement { +function MessageSignature ({ message: { args, mutates, name, returnType }, params = [], asConstructor = false, withTooltip = false }: Props): React.ReactElement { const { t } = useTranslation(); return ( @@ -107,3 +107,5 @@ export default function MessageSignature ({ message: { args, mutates, name, retu ); } + +export default React.memo(MessageSignature); diff --git a/packages/page-contracts/src/Params.tsx b/packages/page-contracts/src/Params.tsx index ecc34b694c..9215367d4f 100644 --- a/packages/page-contracts/src/Params.tsx +++ b/packages/page-contracts/src/Params.tsx @@ -21,7 +21,7 @@ interface ParamDef { type: TypeDef; } -export default function Params ({ isDisabled, onChange, onEnter, params: propParams }: Props): React.ReactElement | null { +function Params ({ isDisabled, onChange, onEnter, params: propParams }: Props): React.ReactElement | null { const [params, setParams] = useState([]); useEffect((): void => { @@ -45,3 +45,5 @@ export default function Params ({ isDisabled, onChange, onEnter, params: propPar /> ); } + +export default React.memo(Params); diff --git a/packages/page-contracts/src/RemoveABI.tsx b/packages/page-contracts/src/RemoveABI.tsx index 6ccb73751e..80b6e7b812 100644 --- a/packages/page-contracts/src/RemoveABI.tsx +++ b/packages/page-contracts/src/RemoveABI.tsx @@ -16,7 +16,7 @@ interface Props { onRemove: () => void; } -export default function RemoveABI ({ code, onClose, onRemove }: Props): React.ReactElement { +function RemoveABI ({ code, onClose, onRemove }: Props): React.ReactElement { const { t } = useTranslation(); const _onRemove = (): void => { @@ -50,3 +50,5 @@ export default function RemoveABI ({ code, onClose, onRemove }: Props): React.Re ); } + +export default React.memo(RemoveABI); diff --git a/packages/page-council/src/Motions/Motion.tsx b/packages/page-council/src/Motions/Motion.tsx index 07a83096e4..f9afbe3e2c 100644 --- a/packages/page-council/src/Motions/Motion.tsx +++ b/packages/page-council/src/Motions/Motion.tsx @@ -24,7 +24,7 @@ interface Props { prime: AccountId | null; } -export default function Motion ({ className, isMember, members, motion: { hash, proposal, votes }, prime }: Props): React.ReactElement | null { +function Motion ({ className, isMember, members, motion: { hash, proposal, votes }, prime }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const bestNumber = useCall(api.derive.chain.bestNumber, []) || new BN(0); @@ -94,3 +94,5 @@ export default function Motion ({ className, isMember, members, motion: { hash, ); } + +export default React.memo(Motion); diff --git a/packages/page-council/src/Motions/Voting.tsx b/packages/page-council/src/Motions/Voting.tsx index 80e7881a3b..b8becdd1ac 100644 --- a/packages/page-council/src/Motions/Voting.tsx +++ b/packages/page-council/src/Motions/Voting.tsx @@ -20,7 +20,7 @@ interface Props { proposal: Proposal; } -export default function Voting ({ hash, idNumber, isDisabled, members, prime, proposal }: Props): React.ReactElement | null { +function Voting ({ hash, idNumber, isDisabled, members, prime, proposal }: Props): React.ReactElement | null { const { t } = useTranslation(); const { hasAccounts } = useAccounts(); const [isVotingOpen, toggleVoting] = useToggle(); @@ -77,3 +77,5 @@ export default function Voting ({ hash, idNumber, isDisabled, members, prime, pr ); } + +export default React.memo(Voting); diff --git a/packages/page-council/src/useCouncilMembers.ts b/packages/page-council/src/useCouncilMembers.ts index 21fd3c9581..5d54574e5b 100644 --- a/packages/page-council/src/useCouncilMembers.ts +++ b/packages/page-council/src/useCouncilMembers.ts @@ -4,29 +4,33 @@ import { AccountId, Balance } from '@polkadot/types/interfaces'; +import { useEffect, useState } from 'react'; import { useAccounts, useApi, useCall } from '@polkadot/react-hooks'; interface Result { isMember: boolean; members: string[]; } -function transform (allAccounts: string[]): (queryMembers: [AccountId, Balance][]) => Result { - return (queryMembers: [AccountId, Balance][]): Result => { - const members = queryMembers.map((accountId): string => accountId.toString()); +function transform (allAccounts: string[], queryMembers: [AccountId, Balance][]): Result { + const members = queryMembers.map((accountId): string => accountId.toString()); - return { - members, - isMember: members.some((accountId): boolean => allAccounts.includes(accountId)) - }; + return { + members, + isMember: members.some((accountId): boolean => allAccounts.includes(accountId)) }; } export default function useCouncilMembers (): Result { const { api } = useApi(); const { allAccounts } = useAccounts(); - const members = useCall(!!allAccounts.length && api.query.council.members, [], { - transform: transform(allAccounts) - }) || { isMember: false, members: [] }; + const [state, setState] = useState({ isMember: false, members: [] }); + const queryMembers = useCall<[AccountId, Balance][]>(api.query.council.members, []); - return members; + useEffect((): void => { + allAccounts && queryMembers && setState( + transform(allAccounts, queryMembers) + ); + }, [allAccounts, queryMembers]); + + return state; } diff --git a/packages/page-dashboard/src/Spacer.tsx b/packages/page-dashboard/src/Spacer.tsx index 7cef9a3a89..78710aedcf 100644 --- a/packages/page-dashboard/src/Spacer.tsx +++ b/packages/page-dashboard/src/Spacer.tsx @@ -6,8 +6,10 @@ import React from 'react'; type Props = {}; -export default function Spacer (): React.ReactElement { +function Spacer (): React.ReactElement { return (

); } + +export default React.memo(Spacer); diff --git a/packages/page-democracy/src/index.tsx b/packages/page-democracy/src/index.tsx index ce5cdee467..95e1e07267 100644 --- a/packages/page-democracy/src/index.tsx +++ b/packages/page-democracy/src/index.tsx @@ -21,7 +21,7 @@ const hidden = uiSettings.uiMode === 'full' ? [] : ['propose']; -export default function DemocracyApp ({ basePath }: Props): React.ReactElement { +function DemocracyApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -47,3 +47,5 @@ export default function DemocracyApp ({ basePath }: Props): React.ReactElement

); } + +export default React.memo(DemocracyApp); diff --git a/packages/page-democracy/src/useCounter.ts b/packages/page-democracy/src/useCounter.ts index 34f17c854b..5d59ebb21e 100644 --- a/packages/page-democracy/src/useCounter.ts +++ b/packages/page-democracy/src/useCounter.ts @@ -9,7 +9,7 @@ export default function useCounter (): number { const { api, isApiReady } = useApi(); const mountedRef = useIsMountedRef(); const proposals = useCall(isApiReady && api.derive.democracy?.proposals, []); - const referenda = useCall(isApiReady && api.derive.democracy?.referendums, []); + const referenda = useCall(isApiReady && api.derive.democracy?.referendumsActive, []); const [counter, setCounter] = useState(0); useEffect((): void => { diff --git a/packages/page-explorer/src/NodeInfo/index.tsx b/packages/page-explorer/src/NodeInfo/index.tsx index cb629185c4..f290e0183d 100644 --- a/packages/page-explorer/src/NodeInfo/index.tsx +++ b/packages/page-explorer/src/NodeInfo/index.tsx @@ -30,7 +30,7 @@ async function retrieveInfo (api: ApiPromise): Promise> { } } -export default function NodeInfo (): React.ReactElement<{}> { +function NodeInfo (): React.ReactElement<{}> { const { t } = useTranslation(); const { api } = useApi(); const [info, setInfo] = useState>({}); @@ -68,3 +68,5 @@ export default function NodeInfo (): React.ReactElement<{}> { ); } + +export default React.memo(NodeInfo); diff --git a/packages/page-extrinsics/src/Balance.tsx b/packages/page-extrinsics/src/Balance.tsx index ecc1606f34..4c2edc9508 100644 --- a/packages/page-extrinsics/src/Balance.tsx +++ b/packages/page-extrinsics/src/Balance.tsx @@ -14,7 +14,7 @@ interface Props extends BareProps { params?: any; } -export default function BalanceDisplay ({ className, label, params, style }: Props): React.ReactElement { +function BalanceDisplay ({ className, label, params, style }: Props): React.ReactElement { const { api } = useApi(); const allBalances = useCall(api.derive.balances.all as any, [params]); @@ -28,3 +28,5 @@ export default function BalanceDisplay ({ className, label, params, style }: Pro /> ); } + +export default React.memo(BalanceDisplay); diff --git a/packages/page-extrinsics/src/index.tsx b/packages/page-extrinsics/src/index.tsx index 328b10a07c..8c0416b7d0 100644 --- a/packages/page-extrinsics/src/index.tsx +++ b/packages/page-extrinsics/src/index.tsx @@ -10,7 +10,7 @@ import { Tabs } from '@polkadot/react-components'; import Selection from './Selection'; import { useTranslation } from './translate'; -export default function ExtrinsicsApp ({ basePath }: Props): React.ReactElement { +function ExtrinsicsApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [{ isRoot: true, @@ -32,3 +32,5 @@ export default function ExtrinsicsApp ({ basePath }: Props): React.ReactElement< } export { ExtrinsicsApp }; + +export default React.memo(ExtrinsicsApp); diff --git a/packages/page-generic-asset/src/index.tsx b/packages/page-generic-asset/src/index.tsx index 61ada78e1f..d7a78f0857 100644 --- a/packages/page-generic-asset/src/index.tsx +++ b/packages/page-generic-asset/src/index.tsx @@ -15,7 +15,7 @@ import { useTranslation } from './translate'; interface Props extends AppProps, BareProps {} -export default function AssetApp ({ basePath }: Props): React.ReactElement { +function AssetApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -44,3 +44,5 @@ export default function AssetApp ({ basePath }: Props): React.ReactElement ); } + +export default React.memo(AssetApp); diff --git a/packages/page-generic-asset/src/modals/Create.tsx b/packages/page-generic-asset/src/modals/Create.tsx index 5eca03b4d4..a016f1a39a 100644 --- a/packages/page-generic-asset/src/modals/Create.tsx +++ b/packages/page-generic-asset/src/modals/Create.tsx @@ -17,7 +17,7 @@ interface Props extends ModalProps { className?: string; } -export default function Create ({ onClose, onRegister }: Props): React.ReactElement { +function Create ({ onClose, onRegister }: Props): React.ReactElement { const { t } = useTranslation(); const [assetId, setAssetId] = useState(new BN(0)); const [name, setName] = useState('new asset'); @@ -60,3 +60,5 @@ export default function Create ({ onClose, onRegister }: Props): React.ReactElem ); } + +export default React.memo(Create); diff --git a/packages/page-js/src/ActionButtons.tsx b/packages/page-js/src/ActionButtons.tsx index c3e70c132b..b8db2b0266 100644 --- a/packages/page-js/src/ActionButtons.tsx +++ b/packages/page-js/src/ActionButtons.tsx @@ -20,7 +20,7 @@ interface Props extends BareProps { stopJs: () => void; } -export default function ActionButtons ({ className, isCustomExample, isRunning, removeSnippet, runJs, saveSnippet, stopJs }: Props): React.ReactElement { +function ActionButtons ({ className, isCustomExample, isRunning, removeSnippet, runJs, saveSnippet, stopJs }: Props): React.ReactElement { const { t } = useTranslation(); const [isOpen, setIsOpen] = useState(false); const [snippetName, setSnippetName] = useState(''); @@ -115,3 +115,5 @@ export default function ActionButtons ({ className, isCustomExample, isRunning,

); } + +export default React.memo(ActionButtons); diff --git a/packages/page-js/src/index.tsx b/packages/page-js/src/index.tsx index 0261bb1387..fdec61e21a 100644 --- a/packages/page-js/src/index.tsx +++ b/packages/page-js/src/index.tsx @@ -8,6 +8,8 @@ import React from 'react'; import Playground from './Playground'; -export default function JsApp (props: Props): React.ReactElement { +function JsApp (props: Props): React.ReactElement { return ; } + +export default React.memo(JsApp); diff --git a/packages/page-parachains/src/Overview/Register.tsx b/packages/page-parachains/src/Overview/Register.tsx index fdfc2898f1..3d7fd3d26c 100644 --- a/packages/page-parachains/src/Overview/Register.tsx +++ b/packages/page-parachains/src/Overview/Register.tsx @@ -32,7 +32,7 @@ const schedulingOptions = [{ const ONE_THOUSAND = new BN(1000); -export default function Register ({ nextFreeId = ONE_THOUSAND, sudoKey }: Props): React.ReactElement | null { +function Register ({ nextFreeId = ONE_THOUSAND, sudoKey }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const { isOpen, onOpen, onClose } = useModal(); @@ -152,3 +152,5 @@ export default function Register ({ nextFreeId = ONE_THOUSAND, sudoKey }: Props) ); } + +export default React.memo(Register); diff --git a/packages/page-parachains/src/Overview/index.tsx b/packages/page-parachains/src/Overview/index.tsx index 8ed7a7f2eb..99d0592967 100644 --- a/packages/page-parachains/src/Overview/index.tsx +++ b/packages/page-parachains/src/Overview/index.tsx @@ -16,7 +16,7 @@ import Summary from './Summary'; import { useTranslation } from '../translate'; -export default function Overview ({ isMine, sudoKey }: Props): React.ReactElement { +function Overview ({ isMine, sudoKey }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const parachains = useCall(api.derive.parachains.overview) || null; @@ -66,3 +66,5 @@ export default function Overview ({ isMine, sudoKey }: Props): React.ReactElemen ); } + +export default React.memo(Overview); diff --git a/packages/page-parachains/src/Parachain/Deregister.tsx b/packages/page-parachains/src/Parachain/Deregister.tsx index fa02792427..ea838e65e9 100644 --- a/packages/page-parachains/src/Parachain/Deregister.tsx +++ b/packages/page-parachains/src/Parachain/Deregister.tsx @@ -23,7 +23,7 @@ interface Props { sudoKey: string; } -export default function Deregister ({ id, info, isOpen, onClose, onSubmit, sudoKey }: Props): React.ReactElement | null { +function Deregister ({ id, info, isOpen, onClose, onSubmit, sudoKey }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const onSendRef = useRef<() => void>(); @@ -77,3 +77,5 @@ export default function Deregister ({ id, info, isOpen, onClose, onSubmit, sudoK ); } + +export default React.memo(Deregister); diff --git a/packages/page-parachains/src/index.tsx b/packages/page-parachains/src/index.tsx index 922fec8242..9bb8fbc0af 100644 --- a/packages/page-parachains/src/index.tsx +++ b/packages/page-parachains/src/index.tsx @@ -18,7 +18,7 @@ import { parachainName } from './util'; interface Props extends AppProps, BareProps {} -export default function ParachainsApp ({ basePath }: Props): React.ReactElement { +function ParachainsApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const sudoState = useSudo(); const paraInfoRef = useRef(null); @@ -65,3 +65,5 @@ export default function ParachainsApp ({ basePath }: Props): React.ReactElement< ); } + +export default React.memo(ParachainsApp); diff --git a/packages/page-settings/src/General.tsx b/packages/page-settings/src/General.tsx index 1dc3768750..ff5b3e5123 100644 --- a/packages/page-settings/src/General.tsx +++ b/packages/page-settings/src/General.tsx @@ -22,7 +22,7 @@ interface Props { const ledgerConnOptions = uiSettings.availableLedgerConn; -export default function General ({ className, isModalContent, onClose }: Props): React.ReactElement { +function General ({ className, isModalContent, onClose }: Props): React.ReactElement { const { t } = useTranslation(); // tri-state: null = nothing changed, false = no reload, true = reload required const [changed, setChanged] = useState(null); @@ -150,3 +150,5 @@ export default function General ({ className, isModalContent, onClose }: Props): ); } + +export default React.memo(General); diff --git a/packages/page-settings/src/index.tsx b/packages/page-settings/src/index.tsx index 033828fd7e..7f328dfa48 100644 --- a/packages/page-settings/src/index.tsx +++ b/packages/page-settings/src/index.tsx @@ -19,7 +19,7 @@ const hidden = uiSettings.uiMode === 'full' ? [] : ['developer']; -export default function SettingsApp ({ basePath, onStatusChange }: Props): React.ReactElement { +function SettingsApp ({ basePath, onStatusChange }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -55,3 +55,5 @@ export default function SettingsApp ({ basePath, onStatusChange }: Props): React ); } + +export default React.memo(SettingsApp); diff --git a/packages/page-society/src/Overview/Bid.tsx b/packages/page-society/src/Overview/Bid.tsx index 49b4b42ef2..5ebcf8c158 100644 --- a/packages/page-society/src/Overview/Bid.tsx +++ b/packages/page-society/src/Overview/Bid.tsx @@ -14,7 +14,7 @@ interface Props { value: Bid; } -export default function BidRow ({ value: { who, kind, value } }: Props): React.ReactElement { +function BidRow ({ value: { who, kind, value } }: Props): React.ReactElement { const { t } = useTranslation(); return ( @@ -35,3 +35,5 @@ export default function BidRow ({ value: { who, kind, value } }: Props): React.R ); } + +export default React.memo(BidRow); diff --git a/packages/page-society/src/Overview/Candidate.tsx b/packages/page-society/src/Overview/Candidate.tsx index ef3abe8426..6adc52a884 100644 --- a/packages/page-society/src/Overview/Candidate.tsx +++ b/packages/page-society/src/Overview/Candidate.tsx @@ -23,7 +23,7 @@ interface Props { value: DeriveSocietyCandidate; } -export default function Candidate ({ allMembers, isMember, ownMembers, value: { accountId, kind, value } }: Props): React.ReactElement { +function Candidate ({ allMembers, isMember, ownMembers, value: { accountId, kind, value } }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const votes = useCall(api.query.society.votes.multi as any, [allMembers.map((memberId): [AccountId, string] => [accountId, memberId])] as any, { @@ -60,3 +60,5 @@ export default function Candidate ({ allMembers, isMember, ownMembers, value: { ); } + +export default React.memo(Candidate); diff --git a/packages/page-society/src/Overview/CandidateVoting.tsx b/packages/page-society/src/Overview/CandidateVoting.tsx index 40762bfbe8..070060deaf 100644 --- a/packages/page-society/src/Overview/CandidateVoting.tsx +++ b/packages/page-society/src/Overview/CandidateVoting.tsx @@ -14,7 +14,7 @@ interface Props { ownMembers: string[]; } -export default function CandidateVoting ({ candidateId, isMember, ownMembers }: Props): React.ReactElement { +function CandidateVoting ({ candidateId, isMember, ownMembers }: Props): React.ReactElement { const { t } = useTranslation(); const [isVisible, toggleVisible] = useToggle(); const [vote, setVote] = useState(true); @@ -65,3 +65,5 @@ export default function CandidateVoting ({ candidateId, isMember, ownMembers }: ); } + +export default React.memo(CandidateVoting); diff --git a/packages/page-society/src/Overview/Candidates.tsx b/packages/page-society/src/Overview/Candidates.tsx index c16c9769be..7eb3414848 100644 --- a/packages/page-society/src/Overview/Candidates.tsx +++ b/packages/page-society/src/Overview/Candidates.tsx @@ -16,7 +16,7 @@ interface Props extends OwnMembers { className?: string; } -export default function Candidates ({ allMembers, className, isMember, ownMembers }: Props): React.ReactElement { +function Candidates ({ allMembers, className, isMember, ownMembers }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const candidates = useCall(api.derive.society.candidates, []); @@ -47,3 +47,5 @@ export default function Candidates ({ allMembers, className, isMember, ownMember ); } + +export default React.memo(Candidates); diff --git a/packages/page-society/src/Overview/Defender.tsx b/packages/page-society/src/Overview/Defender.tsx index e51e62c992..90b2dc16b0 100644 --- a/packages/page-society/src/Overview/Defender.tsx +++ b/packages/page-society/src/Overview/Defender.tsx @@ -19,7 +19,7 @@ interface Props extends OwnMembers { info?: DeriveSociety; } -export default function Defender ({ className, info, isMember, ownMembers }: Props): React.ReactElement | null { +function Defender ({ className, info, isMember, ownMembers }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const votes = useCall(api.derive.society.members, [], { @@ -55,3 +55,5 @@ export default function Defender ({ className, info, isMember, ownMembers }: Pro ); } + +export default React.memo(Defender); diff --git a/packages/page-society/src/Overview/DefenderVoting.tsx b/packages/page-society/src/Overview/DefenderVoting.tsx index 7346b4aa25..529e491eca 100644 --- a/packages/page-society/src/Overview/DefenderVoting.tsx +++ b/packages/page-society/src/Overview/DefenderVoting.tsx @@ -13,7 +13,7 @@ interface Props { ownMembers: string[]; } -export default function DefenderVoting ({ isMember, ownMembers }: Props): React.ReactElement { +function DefenderVoting ({ isMember, ownMembers }: Props): React.ReactElement { const { t } = useTranslation(); const [isVisible, toggleVisible] = useToggle(); const [vote, setVote] = useState(true); @@ -63,3 +63,5 @@ export default function DefenderVoting ({ isMember, ownMembers }: Props): React. ); } + +export default React.memo(DefenderVoting); diff --git a/packages/page-society/src/Overview/Members.tsx b/packages/page-society/src/Overview/Members.tsx index d04bf5ff5b..51ed1270f9 100644 --- a/packages/page-society/src/Overview/Members.tsx +++ b/packages/page-society/src/Overview/Members.tsx @@ -16,7 +16,7 @@ interface Props { info?: DeriveSociety; } -export default function Members ({ className, info }: Props): React.ReactElement { +function Members ({ className, info }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const members = useCall(api.derive.society.members, []); @@ -52,3 +52,5 @@ export default function Members ({ className, info }: Props): React.ReactElement ); } + +export default React.memo(Members); diff --git a/packages/page-society/src/index.tsx b/packages/page-society/src/index.tsx index 320e90510c..192d801a13 100644 --- a/packages/page-society/src/index.tsx +++ b/packages/page-society/src/index.tsx @@ -13,7 +13,7 @@ import { useTranslation } from './translate'; interface Props extends AppProps, BareProps {} -export default function SocietyApp ({ basePath, className }: Props): React.ReactElement { +function SocietyApp ({ basePath, className }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -37,3 +37,5 @@ export default function SocietyApp ({ basePath, className }: Props): React.React ); } + +export default React.memo(SocietyApp); diff --git a/packages/page-society/src/useMembers.ts b/packages/page-society/src/useMembers.ts index cc409b33be..ed53fb2421 100644 --- a/packages/page-society/src/useMembers.ts +++ b/packages/page-society/src/useMembers.ts @@ -5,26 +5,30 @@ import { DeriveSocietyMember } from '@polkadot/api-derive/types'; import { OwnMembers } from './types'; +import { useEffect, useState } from 'react'; import { useAccounts, useApi, useCall } from '@polkadot/react-hooks'; -function transform (allAccounts: string[]): (members: DeriveSocietyMember[]) => OwnMembers { - return (members: DeriveSocietyMember[]): OwnMembers => { - const allMembers = members - .filter((member): boolean => !member.isSuspended) - .map((member): string => member.accountId.toString()); - const ownMembers = allMembers - .filter((address): boolean => allAccounts.includes(address)); +function transform (allAccounts: string[], members: DeriveSocietyMember[]): OwnMembers { + const allMembers = members + .filter((member): boolean => !member.isSuspended) + .map((member): string => member.accountId.toString()); + const ownMembers = allMembers + .filter((address): boolean => allAccounts.includes(address)); - return { allMembers, isMember: ownMembers.length !== 0, ownMembers }; - }; + return { allMembers, isMember: ownMembers.length !== 0, ownMembers }; } export default function useMembers (): OwnMembers { const { api } = useApi(); const { allAccounts } = useAccounts(); - const state = useCall(!!allAccounts.length && api.derive.society?.members, [], { - transform: transform(allAccounts) - }) || { allMembers: [], isMember: false, ownMembers: [] }; + const [state, setState] = useState({ allMembers: [], isMember: false, ownMembers: [] }); + const members = useCall(api.derive.society?.members, []); + + useEffect((): void => { + allAccounts && members && setState( + transform(allAccounts, members) + ); + }, [allAccounts, members]); return state; } diff --git a/packages/page-storage/src/Queries.tsx b/packages/page-storage/src/Queries.tsx index 7508e2dcf1..4092dbfda4 100644 --- a/packages/page-storage/src/Queries.tsx +++ b/packages/page-storage/src/Queries.tsx @@ -14,7 +14,7 @@ interface Props extends BareProps { value?: QueryTypes[]; } -export default function Queries ({ onRemove, value }: Props): React.ReactElement | null { +function Queries ({ onRemove, value }: Props): React.ReactElement | null { if (!value || !value.length) { return null; } @@ -31,3 +31,5 @@ export default function Queries ({ onRemove, value }: Props): React.ReactElement ); } + +export default React.memo(Queries); diff --git a/packages/page-storage/src/Selection/Consts.tsx b/packages/page-storage/src/Selection/Consts.tsx index d7af269c93..97d7e9f509 100644 --- a/packages/page-storage/src/Selection/Consts.tsx +++ b/packages/page-storage/src/Selection/Consts.tsx @@ -12,7 +12,7 @@ import { useApi } from '@polkadot/react-hooks'; import { useTranslation } from '../translate'; -export default function Consts ({ onAdd }: Props): React.ReactElement { +function Consts ({ onAdd }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const [defaultValue] = useState((): ConstValue => { @@ -52,3 +52,5 @@ export default function Consts ({ onAdd }: Props): React.ReactElement { ); } + +export default React.memo(Consts); diff --git a/packages/page-storage/src/Selection/Modules.tsx b/packages/page-storage/src/Selection/Modules.tsx index 4a1b81ace6..64451c5c3d 100644 --- a/packages/page-storage/src/Selection/Modules.tsx +++ b/packages/page-storage/src/Selection/Modules.tsx @@ -64,7 +64,7 @@ function expandKey (api: ApiPromise, key: StorageEntryPromise): KeyState { }; } -export default function Modules ({ onAdd }: Props): React.ReactElement { +function Modules ({ onAdd }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const [{ defaultValues, isIterable, key, params }, setKey] = useState({ defaultValues: undefined, isIterable: false, key: api.query.timestamp.now, params: [] }); @@ -116,3 +116,5 @@ export default function Modules ({ onAdd }: Props): React.ReactElement { ); } + +export default React.memo(Modules); diff --git a/packages/page-storage/src/Selection/Raw.tsx b/packages/page-storage/src/Selection/Raw.tsx index c566e16d3c..ee66a553e8 100644 --- a/packages/page-storage/src/Selection/Raw.tsx +++ b/packages/page-storage/src/Selection/Raw.tsx @@ -11,7 +11,7 @@ import { useTranslation } from '../translate'; import { u8aToU8a } from '@polkadot/util'; import { Compact } from '@polkadot/types'; -export default function Raw ({ onAdd }: Props): React.ReactElement { +function Raw ({ onAdd }: Props): React.ReactElement { const { t } = useTranslation(); const [{ isValid, key }, setValue] = useState<{ isValid: boolean; key: Uint8Array }>({ isValid: false, key: new Uint8Array([]) }); @@ -49,3 +49,5 @@ export default function Raw ({ onAdd }: Props): React.ReactElement { ); } + +export default React.memo(Raw); diff --git a/packages/page-storage/src/Selection/index.tsx b/packages/page-storage/src/Selection/index.tsx index b1ea0deeab..1c14b949cf 100644 --- a/packages/page-storage/src/Selection/index.tsx +++ b/packages/page-storage/src/Selection/index.tsx @@ -20,7 +20,7 @@ interface Props { let id = -1; -export default function Selection ({ basePath, onAdd }: Props): React.ReactElement { +function Selection ({ basePath, onAdd }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -59,3 +59,5 @@ export default function Selection ({ basePath, onAdd }: Props): React.ReactEleme ); } + +export default React.memo(Selection); diff --git a/packages/page-sudo/src/index.tsx b/packages/page-sudo/src/index.tsx index e30a1d07c2..ae034757cd 100644 --- a/packages/page-sudo/src/index.tsx +++ b/packages/page-sudo/src/index.tsx @@ -16,7 +16,7 @@ import Sudo from './Sudo'; import { useTranslation } from './translate'; -export default function SudoApp ({ basePath }: Props): React.ReactElement { +function SudoApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const { allAccounts, sudoKey, isMine } = useSudo(); const items = useMemo(() => [ @@ -71,3 +71,5 @@ export default function SudoApp ({ basePath }: Props): React.ReactElement ); } + +export default React.memo(SudoApp); diff --git a/packages/page-tech-comm/src/Overview/Summary.tsx b/packages/page-tech-comm/src/Overview/Summary.tsx index 4c3aca90e7..2e9c4348bc 100644 --- a/packages/page-tech-comm/src/Overview/Summary.tsx +++ b/packages/page-tech-comm/src/Overview/Summary.tsx @@ -12,7 +12,7 @@ import { formatNumber } from '@polkadot/util'; import { useTranslation } from '../translate'; -export default function Summary ({ className, members, proposals }: Props): React.ReactElement { +function Summary ({ className, members, proposals }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const proposalCount = useCall(api.query.technicalCommittee.proposalCount, []); @@ -33,3 +33,5 @@ export default function Summary ({ className, members, proposals }: Props): Reac ); } + +export default React.memo(Summary); diff --git a/packages/page-tech-comm/src/Overview/index.tsx b/packages/page-tech-comm/src/Overview/index.tsx index d093cd41d4..9a32c9859b 100644 --- a/packages/page-tech-comm/src/Overview/index.tsx +++ b/packages/page-tech-comm/src/Overview/index.tsx @@ -9,7 +9,7 @@ import React from 'react'; import Members from './Members'; import Summary from './Summary'; -export default function Overview ({ className, isMember, members, prime, proposals }: Props): React.ReactElement { +function Overview ({ className, isMember, members, prime, proposals }: Props): React.ReactElement { return (
); } + +export default React.memo(Overview); diff --git a/packages/page-tech-comm/src/Proposals/Proposal.tsx b/packages/page-tech-comm/src/Proposals/Proposal.tsx index fb1fc02fc1..2f0d5ccb3d 100644 --- a/packages/page-tech-comm/src/Proposals/Proposal.tsx +++ b/packages/page-tech-comm/src/Proposals/Proposal.tsx @@ -20,7 +20,7 @@ interface Props { prime?: AccountId | null; } -export default function Proposal ({ className, hash, prime }: Props): React.ReactElement | null { +function Proposal ({ className, hash, prime }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const optProposal = useCall>(api.query.technicalCommittee.proposalOf, [hash]); @@ -75,3 +75,5 @@ export default function Proposal ({ className, hash, prime }: Props): React.Reac ); } + +export default React.memo(Proposal); diff --git a/packages/page-tech-comm/src/Proposals/Voting.tsx b/packages/page-tech-comm/src/Proposals/Voting.tsx index 5edf1ad273..1721c67b73 100644 --- a/packages/page-tech-comm/src/Proposals/Voting.tsx +++ b/packages/page-tech-comm/src/Proposals/Voting.tsx @@ -18,7 +18,7 @@ interface Props { proposalId: BN | number; } -export default function Voting ({ hash, prime, proposalId }: Props): React.ReactElement | null { +function Voting ({ hash, prime, proposalId }: Props): React.ReactElement | null { const { t } = useTranslation(); const { hasAccounts } = useAccounts(); const [accountId, setAccountId] = useState(null); @@ -68,3 +68,5 @@ export default function Voting ({ hash, prime, proposalId }: Props): React.React ); } + +export default React.memo(Voting); diff --git a/packages/page-tech-comm/src/Proposals/index.tsx b/packages/page-tech-comm/src/Proposals/index.tsx index 1ab6efd2e0..133f7d670d 100644 --- a/packages/page-tech-comm/src/Proposals/index.tsx +++ b/packages/page-tech-comm/src/Proposals/index.tsx @@ -12,7 +12,7 @@ import { useTranslation } from '../translate'; import Proposal from './Proposal'; import Propose from './Propose'; -export default function Proposals ({ className, isMember, members, prime, proposals }: Props): React.ReactElement { +function Proposals ({ className, isMember, members, prime, proposals }: Props): React.ReactElement { const { t } = useTranslation(); return ( @@ -42,3 +42,5 @@ export default function Proposals ({ className, isMember, members, prime, propos
); } + +export default React.memo(Proposals); diff --git a/packages/page-toolbox/src/Hash.tsx b/packages/page-toolbox/src/Hash.tsx index 8882bfd523..49d6f85e77 100644 --- a/packages/page-toolbox/src/Hash.tsx +++ b/packages/page-toolbox/src/Hash.tsx @@ -15,7 +15,7 @@ interface State { isHexData: boolean; } -export default function Hash (): React.ReactElement<{}> { +function Hash (): React.ReactElement<{}> { const { t } = useTranslation(); const [{ data, hash, isHexData }, setState] = useState({ data: '', @@ -76,3 +76,5 @@ export default function Hash (): React.ReactElement<{}> { ); } + +export default React.memo(Hash); diff --git a/packages/page-toolbox/src/Rpc/Results.tsx b/packages/page-toolbox/src/Rpc/Results.tsx index e7d80e5ef1..27c5030ede 100644 --- a/packages/page-toolbox/src/Rpc/Results.tsx +++ b/packages/page-toolbox/src/Rpc/Results.tsx @@ -13,7 +13,7 @@ interface Props extends BareProps { queue: QueueTx[]; } -export default function Results ({ queue = [] }: Props): React.ReactElement | null { +function Results ({ queue = [] }: Props): React.ReactElement | null { const filtered = queue .filter(({ error, result }): boolean => !isUndefined(error) || !isUndefined(result) @@ -41,3 +41,5 @@ export default function Results ({ queue = [] }: Props): React.ReactElement ); } + +export default React.memo(Results); diff --git a/packages/page-toolbox/src/Rpc/index.tsx b/packages/page-toolbox/src/Rpc/index.tsx index 9480e12f0b..561da6f6d4 100644 --- a/packages/page-toolbox/src/Rpc/index.tsx +++ b/packages/page-toolbox/src/Rpc/index.tsx @@ -10,7 +10,7 @@ import { QueueConsumer } from '@polkadot/react-components/Status/Context'; import Results from './Results'; import Selection from './Selection'; -export default function RpcApp (): React.ReactElement { +function RpcApp (): React.ReactElement { return ( {({ txqueue, queueRpc }: QueueProps): React.ReactNode => ( @@ -22,3 +22,5 @@ export default function RpcApp (): React.ReactElement { ); } + +export default React.memo(RpcApp); diff --git a/packages/page-toolbox/src/Verify.tsx b/packages/page-toolbox/src/Verify.tsx index 1e91e21ad7..2c8a6d7290 100644 --- a/packages/page-toolbox/src/Verify.tsx +++ b/packages/page-toolbox/src/Verify.tsx @@ -33,7 +33,7 @@ const AlignedIcon = styled(Icon)` } `; -export default function Verify (): React.ReactElement<{}> { +function Verify (): React.ReactElement<{}> { const { t } = useTranslation(); const [{ cryptoType, isValid }, setValidity] = useState<{ cryptoType: CryptoTypes; isValid: boolean }>({ cryptoType: 'unknown', isValid: false }); const [{ data, isHexData }, setData] = useState<{ data: string; isHexData: boolean }>({ data: '', isHexData: false }); @@ -157,3 +157,5 @@ export default function Verify (): React.ReactElement<{}> { ); } + +export default React.memo(Verify); diff --git a/packages/page-toolbox/src/index.tsx b/packages/page-toolbox/src/index.tsx index f8ee676cfd..f44e7ddd36 100644 --- a/packages/page-toolbox/src/index.tsx +++ b/packages/page-toolbox/src/index.tsx @@ -15,7 +15,7 @@ import Sign from './Sign'; import Verify from './Verify'; import { useTranslation } from './translate'; -export default function ToolboxApp ({ basePath }: Props): React.ReactElement { +function ToolboxApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const { hasAccounts } = useAccounts(); const items = useMemo(() => [ @@ -60,3 +60,5 @@ export default function ToolboxApp ({ basePath }: Props): React.ReactElement ); } + +export default React.memo(ToolboxApp); diff --git a/packages/page-transfer/.skip-build b/packages/page-transfer/.skip-build deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/packages/page-transfer/.skip-npm b/packages/page-transfer/.skip-npm deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/packages/page-transfer/LICENSE b/packages/page-transfer/LICENSE deleted file mode 100644 index 0d381b2e97..0000000000 --- a/packages/page-transfer/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - -TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - -1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - -2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - -3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - -4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - -5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - -6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - -7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - -8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - -9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - -END OF TERMS AND CONDITIONS - -APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - -Copyright [yyyy] [name of copyright owner] - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. diff --git a/packages/page-transfer/README.md b/packages/page-transfer/README.md deleted file mode 100644 index 2823a5a361..0000000000 --- a/packages/page-transfer/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# @polkadot/app-transfer - -A basic DOT transfer application, allowing the movement of funds from one account to another. diff --git a/packages/page-transfer/package.json b/packages/page-transfer/package.json deleted file mode 100644 index e5572393e8..0000000000 --- a/packages/page-transfer/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "@polkadot/app-transfer", - "version": "0.40.0-beta.184", - "description": "A basic transfer app", - "main": "index.js", - "scripts": {}, - "author": "Jaco Greeff ", - "maintainers": [ - "Jaco Greeff " - ], - "license": "Apache-2.0", - "dependencies": { - "@babel/runtime": "^7.9.2", - "@polkadot/react-components": "0.40.0-beta.184", - "@polkadot/react-query": "0.40.0-beta.184" - } -} diff --git a/packages/page-transfer/src/index.tsx b/packages/page-transfer/src/index.tsx deleted file mode 100644 index b48fba1f2b..0000000000 --- a/packages/page-transfer/src/index.tsx +++ /dev/null @@ -1,13 +0,0 @@ -// Copyright 2017-2020 @polkadot/app-transfer authors & contributors -// This software may be modified and distributed under the terms -// of the Apache-2.0 license. See the LICENSE file for details. - -import React from 'react'; - -export default function App (): React.ReactElement { - return ( - <> - Deprecated, now operates via modal - - ); -} diff --git a/packages/page-treasury/src/Overview/Proposals.tsx b/packages/page-treasury/src/Overview/Proposals.tsx index 5512e87831..b463bcd5d7 100644 --- a/packages/page-treasury/src/Overview/Proposals.tsx +++ b/packages/page-treasury/src/Overview/Proposals.tsx @@ -19,7 +19,7 @@ interface Props { proposals?: DerivedTreasuryProposal[]; } -export default function ProposalsBase ({ className, isApprovals, proposals }: Props): React.ReactElement { +function ProposalsBase ({ className, isApprovals, proposals }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const { allAccounts } = useAccounts(); @@ -61,3 +61,5 @@ export default function ProposalsBase ({ className, isApprovals, proposals }: Pr ); } + +export default React.memo(ProposalsBase); diff --git a/packages/page-treasury/src/Overview/Propose.tsx b/packages/page-treasury/src/Overview/Propose.tsx index db5a59dcfe..29c48628be 100644 --- a/packages/page-treasury/src/Overview/Propose.tsx +++ b/packages/page-treasury/src/Overview/Propose.tsx @@ -13,7 +13,7 @@ interface Props { className?: string; } -export default function Propose ({ className }: Props): React.ReactElement | null { +function Propose ({ className }: Props): React.ReactElement | null { const { t } = useTranslation(); const [accountId, setAccountId] = useState(null); const [beneficiary, setBeneficiary] = useState(null); @@ -74,3 +74,5 @@ export default function Propose ({ className }: Props): React.ReactElement ); } + +export default React.memo(Propose); diff --git a/packages/page-treasury/src/Overview/Submission.tsx b/packages/page-treasury/src/Overview/Submission.tsx index 3fc2f57481..835d1383cd 100644 --- a/packages/page-treasury/src/Overview/Submission.tsx +++ b/packages/page-treasury/src/Overview/Submission.tsx @@ -17,7 +17,7 @@ interface Props { isDisabled: boolean; } -export default function Submission ({ councilProposals, id, isDisabled }: Props): React.ReactElement | null { +function Submission ({ councilProposals, id, isDisabled }: Props): React.ReactElement | null { const { t } = useTranslation(); const { api } = useApi(); const councilThreshold = useCall(api.query.electionsPhragmen?.members || api.query.elections.members, [], { @@ -97,3 +97,5 @@ export default function Submission ({ councilProposals, id, isDisabled }: Props) ); } + +export default React.memo(Submission); diff --git a/packages/page-treasury/src/Overview/Summary.tsx b/packages/page-treasury/src/Overview/Summary.tsx index 4564f2b8fe..7435b553f1 100644 --- a/packages/page-treasury/src/Overview/Summary.tsx +++ b/packages/page-treasury/src/Overview/Summary.tsx @@ -20,7 +20,7 @@ interface Props { proposalCount?: number; } -export default function Summary ({ approvalCount, proposalCount }: Props): React.ReactElement { +function Summary ({ approvalCount, proposalCount }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const bestNumber = useCall(api.derive.chain.bestNumber as any, []); @@ -66,3 +66,5 @@ export default function Summary ({ approvalCount, proposalCount }: Props): React ); } + +export default React.memo(Summary); diff --git a/packages/page-treasury/src/Overview/Voting.tsx b/packages/page-treasury/src/Overview/Voting.tsx index d735f93e77..337f9c80e0 100644 --- a/packages/page-treasury/src/Overview/Voting.tsx +++ b/packages/page-treasury/src/Overview/Voting.tsx @@ -22,7 +22,7 @@ interface Option { value: number; } -export default function Voting ({ councilProposals, isDisabled }: Props): React.ReactElement | null { +function Voting ({ councilProposals, isDisabled }: Props): React.ReactElement | null { const { t } = useTranslation(); const { hasAccounts } = useAccounts(); const [councilOpts, setCouncilOpts] = useState([]); @@ -106,3 +106,5 @@ export default function Voting ({ councilProposals, isDisabled }: Props): React. ); } + +export default React.memo(Voting); diff --git a/packages/page-treasury/src/Overview/index.tsx b/packages/page-treasury/src/Overview/index.tsx index 81b82716f6..74f689be80 100644 --- a/packages/page-treasury/src/Overview/index.tsx +++ b/packages/page-treasury/src/Overview/index.tsx @@ -15,7 +15,7 @@ import Propose from './Propose'; interface Props extends AppProps, BareProps, I18nProps {} -export default function Overview ({ className }: Props): React.ReactElement { +function Overview ({ className }: Props): React.ReactElement { const { api } = useApi(); const info = useCall(api.derive.treasury.proposals, []); @@ -33,3 +33,5 @@ export default function Overview ({ className }: Props): React.ReactElement ); } + +export default React.memo(Overview); diff --git a/packages/page-treasury/src/index.tsx b/packages/page-treasury/src/index.tsx index 3a528b9837..3c76ebfe85 100644 --- a/packages/page-treasury/src/index.tsx +++ b/packages/page-treasury/src/index.tsx @@ -17,7 +17,7 @@ export { default as useCounter } from './useCounter'; interface Props extends AppProps, BareProps {} -export default function TreasuryApp ({ basePath }: Props): React.ReactElement { +function TreasuryApp ({ basePath }: Props): React.ReactElement { const { t } = useTranslation(); const items = useMemo(() => [ { @@ -42,3 +42,5 @@ export default function TreasuryApp ({ basePath }: Props): React.ReactElement ); } + +export default React.memo(TreasuryApp); diff --git a/packages/react-api/package.json b/packages/react-api/package.json index bd76b04199..a804690f09 100644 --- a/packages/react-api/package.json +++ b/packages/react-api/package.json @@ -31,7 +31,7 @@ "homepage": "https://github.com/polkadot-js/ui/tree/master/packages/ui-reactive#readme", "dependencies": { "@babel/runtime": "^7.9.2", - "@polkadot/api": "^1.9.0-beta.1", + "@polkadot/api": "^1.9.0-beta.6", "@polkadot/extension-dapp": "^0.23.0-beta.9", "rxjs-compat": "^6.5.4" } diff --git a/packages/react-components/src/TxComponent.tsx b/packages/react-components/src/TxComponent.tsx index fd8b984ec6..e2118e2f55 100644 --- a/packages/react-components/src/TxComponent.tsx +++ b/packages/react-components/src/TxComponent.tsx @@ -1,4 +1,4 @@ -// Copyright 2017-2020 @polkadot/app-transfer authors & contributors +// Copyright 2017-2020 @polkadot/react-components authors & contributors // This software may be modified and distributed under the terms // of the Apache-2.0 license. See the LICENSE file for details. diff --git a/packages/react-components/src/i18n.ts b/packages/react-components/src/i18n.ts index 90740bb6a0..f652065e5e 100644 --- a/packages/react-components/src/i18n.ts +++ b/packages/react-components/src/i18n.ts @@ -58,7 +58,6 @@ i18n 'app-sudo', 'app-tech-comm', 'app-toolbox', - 'app-transfer', 'app-treasury', 'apps', 'apps-routing', diff --git a/packages/react-params/src/Param/index.tsx b/packages/react-params/src/Param/index.tsx index fc79c4e58e..6d02d4e4cf 100644 --- a/packages/react-params/src/Param/index.tsx +++ b/packages/react-params/src/Param/index.tsx @@ -18,7 +18,7 @@ interface Props extends BaseProps { overrides?: ComponentMap; } -export default function Param ({ className, defaultValue, isDisabled, isOptional, name, onChange, onEnter, onEscape, overrides, style, type }: Props): React.ReactElement | null { +function Param ({ className, defaultValue, isDisabled, isOptional, name, onChange, onEnter, onEscape, overrides, style, type }: Props): React.ReactElement | null { const compRef = useRef | null>(findComponent(type, overrides)); if (!compRef.current) { @@ -54,3 +54,5 @@ export default function Param ({ className, defaultValue, isDisabled, isOptional /> ); } + +export default React.memo(Param); diff --git a/packages/react-signer/src/Checks/ContractCall.tsx b/packages/react-signer/src/Checks/ContractCall.tsx index 6a8cbcc320..46a61d66c8 100644 --- a/packages/react-signer/src/Checks/ContractCall.tsx +++ b/packages/react-signer/src/Checks/ContractCall.tsx @@ -15,7 +15,7 @@ interface Props { onChange: (fees: State) => void; } -export default function ContractCall ({ endowment, fees, onChange }: Props): React.ReactElement | null { +function ContractCall ({ endowment, fees, onChange }: Props): React.ReactElement | null { const [state, setState] = useState({ extraFees: new BN(0), extraAmount: new BN(0), @@ -43,3 +43,5 @@ export default function ContractCall ({ endowment, fees, onChange }: Props): Rea return null; } + +export default React.memo(ContractCall); diff --git a/packages/react-signer/src/Checks/ContractDeploy.tsx b/packages/react-signer/src/Checks/ContractDeploy.tsx index 1897340a9d..9c92d9d327 100644 --- a/packages/react-signer/src/Checks/ContractDeploy.tsx +++ b/packages/react-signer/src/Checks/ContractDeploy.tsx @@ -15,7 +15,7 @@ interface Props { onChange: (fees: State) => void; } -export default function ContractDeploy ({ endowment, fees, onChange }: Props): React.ReactElement | null { +function ContractDeploy ({ endowment, fees, onChange }: Props): React.ReactElement | null { const [state, setState] = useState({ extraFees: new BN(0), extraAmount: new BN(0), @@ -43,3 +43,5 @@ export default function ContractDeploy ({ endowment, fees, onChange }: Props): R return null; } + +export default React.memo(ContractDeploy); diff --git a/packages/react-signer/src/Checks/Proposal.tsx b/packages/react-signer/src/Checks/Proposal.tsx index 476a48b725..9692812daf 100644 --- a/packages/react-signer/src/Checks/Proposal.tsx +++ b/packages/react-signer/src/Checks/Proposal.tsx @@ -27,7 +27,7 @@ interface State extends ExtraFees { const ZERO = new BN(0); -export default function Proposal ({ deposit, onChange }: Props): React.ReactElement { +function Proposal ({ deposit, onChange }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const minDeposit = api.consts.democracy.minimumDeposit; @@ -84,3 +84,5 @@ export default function Proposal ({ deposit, onChange }: Props): React.ReactElem ); } + +export default React.memo(Proposal); diff --git a/packages/react-signer/src/Checks/Transfer.tsx b/packages/react-signer/src/Checks/Transfer.tsx index 354c1c46b8..6e4a2e0e01 100644 --- a/packages/react-signer/src/Checks/Transfer.tsx +++ b/packages/react-signer/src/Checks/Transfer.tsx @@ -27,7 +27,7 @@ interface State extends ExtraFees { isNoEffect: boolean; } -export default function Transfer ({ amount, fees, onChange, recipientId }: Props): React.ReactElement { +function Transfer ({ amount, fees, onChange, recipientId }: Props): React.ReactElement { const { t } = useTranslation(); const { api } = useApi(); const allBalances = useCall(api.derive.balances.all as any, [recipientId]); @@ -88,3 +88,5 @@ export default function Transfer ({ amount, fees, onChange, recipientId }: Props ); } + +export default React.memo(Transfer); diff --git a/packages/react-signer/src/Checks/index.tsx b/packages/react-signer/src/Checks/index.tsx index ad472bd867..1c5b0bf986 100644 --- a/packages/react-signer/src/Checks/index.tsx +++ b/packages/react-signer/src/Checks/index.tsx @@ -22,7 +22,7 @@ interface Props { tip?: BN; } -export default function Checks ({ accountId, className, extrinsic }: Props): React.ReactElement | null { +function Checks ({ accountId, className, extrinsic }: Props): React.ReactElement | null { const { api } = useApi(); const [dispatchInfo, setDispatchInfo] = useState(null); @@ -49,3 +49,5 @@ export default function Checks ({ accountId, className, extrinsic }: Props): Rea /> ); } + +export default React.memo(Checks); diff --git a/tsconfig.json b/tsconfig.json index 7b2b6403c1..13d15da9fe 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -48,8 +48,6 @@ "@polkadot/app-tech-comm/*": [ "packages/page-tech-comm/src/*" ], "@polkadot/app-toolbox": [ "packages/page-toolbox/src" ], "@polkadot/app-toolbox/*": [ "packages/page-toolbox/src/*" ], - "@polkadot/app-transfer": [ "packages/page-transfer/src" ], - "@polkadot/app-transfer/*": [ "packages/page-transfer/src/*" ], "@polkadot/app-treasury": [ "packages/page-treasury/src" ], "@polkadot/app-treasury/*": [ "packages/page-treasury/src/*" ], "@polkadot/react-api": [ "packages/react-api/src" ], diff --git a/yarn.lock b/yarn.lock index c9121571fe..15b570b559 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2826,56 +2826,56 @@ __metadata: languageName: node linkType: hard -"@polkadot/api-contract@npm:^1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/api-contract@npm:1.9.0-beta.1" +"@polkadot/api-contract@npm:^1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/api-contract@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/api": 1.9.0-beta.1 - "@polkadot/rpc-core": 1.9.0-beta.1 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/api": 1.9.0-beta.6 + "@polkadot/rpc-core": 1.9.0-beta.6 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 bn.js: ^5.1.1 rxjs: ^6.5.4 - checksum: 2/aaac213d2155979fb83e135e7eaf84512948034352e04a64bfdfb7799289ddad258895949a37e46643f4d956c13869e849096ac54124940fc4b1c1e96e8f5e85 + checksum: 2/b25aa5eda0d7ed16c27768d5655ddb23ecb387996550e231bc9764029ec723a620ce9998ace7df26aa0e9c502e85fb9c3a29ed6ebdd2b598e01accfad18a0316 languageName: node linkType: hard -"@polkadot/api-derive@npm:1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/api-derive@npm:1.9.0-beta.1" +"@polkadot/api-derive@npm:1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/api-derive@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/api": 1.9.0-beta.1 - "@polkadot/rpc-core": 1.9.0-beta.1 - "@polkadot/rpc-provider": 1.9.0-beta.1 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/api": 1.9.0-beta.6 + "@polkadot/rpc-core": 1.9.0-beta.6 + "@polkadot/rpc-provider": 1.9.0-beta.6 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 "@polkadot/util-crypto": ^2.7.0-beta.8 bn.js: ^5.1.1 memoizee: ^0.4.14 rxjs: ^6.5.4 - checksum: 2/842be7c2726bf62d96c951ab3bba291b789ca14505fb95a759d27ebed5ebc7d58a6fc922a3be4f91c576bc98249d21cc0c69d6fb5b0cb3e27db200afeecbba06 + checksum: 2/82229dee0cb729b4b4aeea5e6ca19a4e2c1aae0735690c31f7b8ea4e0e074df780e823ea870c63af580942551efe9c6ce140121a4e2e026818735a65a223d4c1 languageName: node linkType: hard -"@polkadot/api@npm:^1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/api@npm:1.9.0-beta.1" +"@polkadot/api@npm:^1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/api@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/api-derive": 1.9.0-beta.1 + "@polkadot/api-derive": 1.9.0-beta.6 "@polkadot/keyring": ^2.7.0-beta.8 - "@polkadot/metadata": 1.9.0-beta.1 - "@polkadot/rpc-core": 1.9.0-beta.1 - "@polkadot/rpc-provider": 1.9.0-beta.1 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/metadata": 1.9.0-beta.6 + "@polkadot/rpc-core": 1.9.0-beta.6 + "@polkadot/rpc-provider": 1.9.0-beta.6 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 "@polkadot/util-crypto": ^2.7.0-beta.8 bn.js: ^5.1.1 eventemitter3: ^4.0.0 rxjs: ^6.5.4 - checksum: 2/35c7869ec522c69a48d25de6485113a44d0f62390a3ddc01f1acf0b0e8fe187e530e8f57c52ab6f13264c88871d9f36059b2930d04b71dbd4e8762ba3343be83 + checksum: 2/ba1b9ac9e313d901ecbdf070570478d4f8bc51e754e5febcd55ca726ae6ac680930495af46d5412c87807e8d941c55b5971b088ee8c470aaf9d43db704c0d324 languageName: node linkType: hard @@ -2916,7 +2916,7 @@ __metadata: resolution: "@polkadot/app-contracts@workspace:packages/page-contracts" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/api-contract": ^1.9.0-beta.1 + "@polkadot/api-contract": ^1.9.0-beta.6 languageName: unknown linkType: soft @@ -3067,16 +3067,6 @@ __metadata: languageName: unknown linkType: soft -"@polkadot/app-transfer@workspace:packages/page-transfer": - version: 0.0.0-use.local - resolution: "@polkadot/app-transfer@workspace:packages/page-transfer" - dependencies: - "@babel/runtime": ^7.9.2 - "@polkadot/react-components": 0.40.0-beta.184 - "@polkadot/react-query": 0.40.0-beta.184 - languageName: unknown - linkType: soft - "@polkadot/app-treasury@workspace:packages/page-treasury": version: 0.0.0-use.local resolution: "@polkadot/app-treasury@workspace:packages/page-treasury" @@ -3250,16 +3240,16 @@ __metadata: languageName: node linkType: hard -"@polkadot/metadata@npm:1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/metadata@npm:1.9.0-beta.1" +"@polkadot/metadata@npm:1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/metadata@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 "@polkadot/util-crypto": ^2.7.0-beta.8 bn.js: ^5.1.1 - checksum: 2/db3cbab0973217b47f8e49d102a86d4ed33ffb69bc6059b2ef41350a29bc8617180d15cc508bc865628872b89cb7a13565ffc2715f0489b92be5bd3b3707afaa + checksum: 2/0a2567492cc5e85cc96afa48622241bf09f4f3272be2c9dc8d880deee7e2a485e0018fdd8f80d0c1be54c23a77607bccb0ec632332e01720bd78881b62a67ce7 languageName: node linkType: hard @@ -3268,7 +3258,7 @@ __metadata: resolution: "@polkadot/react-api@workspace:packages/react-api" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/api": ^1.9.0-beta.1 + "@polkadot/api": ^1.9.0-beta.6 "@polkadot/extension-dapp": ^0.23.0-beta.9 rxjs-compat: ^6.5.4 languageName: unknown @@ -3385,35 +3375,35 @@ __metadata: languageName: unknown linkType: soft -"@polkadot/rpc-core@npm:1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/rpc-core@npm:1.9.0-beta.1" +"@polkadot/rpc-core@npm:1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/rpc-core@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/metadata": 1.9.0-beta.1 - "@polkadot/rpc-provider": 1.9.0-beta.1 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/metadata": 1.9.0-beta.6 + "@polkadot/rpc-provider": 1.9.0-beta.6 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 memoizee: ^0.4.14 rxjs: ^6.5.4 - checksum: 2/9f2b653dec3a645c9e87284766ca331226429a6c2924636ec928fd55214bc9f2918edc113e9090d23963fe556437a78a02f673bc306f1395a800656d4ee69adc + checksum: 2/8d19662f75d95dd1699c6599461df01b87ccb43b9573a770be9906fc1c98d8dd1632bd2e9124d7991c2e254b864fb4f76debfb5fa023b705942c20afd376e52b languageName: node linkType: hard -"@polkadot/rpc-provider@npm:1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/rpc-provider@npm:1.9.0-beta.1" +"@polkadot/rpc-provider@npm:1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/rpc-provider@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/metadata": 1.9.0-beta.1 - "@polkadot/types": 1.9.0-beta.1 + "@polkadot/metadata": 1.9.0-beta.6 + "@polkadot/types": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 "@polkadot/util-crypto": ^2.7.0-beta.8 bn.js: ^5.1.1 eventemitter3: ^4.0.0 isomorphic-fetch: ^2.2.1 websocket: ^1.0.31 - checksum: 2/c7760f893aeb557098bd0854eae8ddb9868289d21cb72c59eca44d38141eee7d8c50e576909e09b7c7fa8a727203c2c385a8b0771a09f12bb1365922d51de667 + checksum: 2/225a4d8504fcc789aca9bac50dca3a1b6b322307bfd0c5814b5a82769717d73866b5757279d3df6b4f24d7ae7bf7ae8cfc688f7985178585f89706adb688351c languageName: node linkType: hard @@ -3426,19 +3416,19 @@ __metadata: languageName: node linkType: hard -"@polkadot/types@npm:^1.9.0-beta.1": - version: 1.9.0-beta.1 - resolution: "@polkadot/types@npm:1.9.0-beta.1" +"@polkadot/types@npm:^1.9.0-beta.6": + version: 1.9.0-beta.6 + resolution: "@polkadot/types@npm:1.9.0-beta.6" dependencies: "@babel/runtime": ^7.9.2 - "@polkadot/metadata": 1.9.0-beta.1 + "@polkadot/metadata": 1.9.0-beta.6 "@polkadot/util": ^2.7.0-beta.8 "@polkadot/util-crypto": ^2.7.0-beta.8 "@types/bn.js": ^4.11.6 bn.js: ^5.1.1 memoizee: ^0.4.14 rxjs: ^6.5.4 - checksum: 2/ed8e3e1b7343b09f56bf64a64b75c9348c41981368866eb5ed542ee12710df4a8410943f2e5994197bc86bacfb776512d4989c58b955972fdb541dea96a9d021 + checksum: 2/bf6fa92828b5b3207d23f8b93331133f41f6f8e01a06a079cebd2441ccb53e6d3cefde57dca4b756705e8e90b873ba5a77cc2d8083e0c89c0b96d98cce0cacb8 languageName: node linkType: hard