From db2697bb9aaf9aa8f662f9e141cc72940de6ed95 Mon Sep 17 00:00:00 2001 From: Thibaut Sardan <33178835+Tbaut@users.noreply.github.com> Date: Tue, 10 Oct 2023 15:52:45 +0100 Subject: [PATCH] Generic accounts displayed in call info (#392) --- packages/ui/src/components/CallInfo.tsx | 13 +++---------- packages/ui/src/utils/isTypeAccount.ts | 2 ++ packages/ui/src/utils/isTypeBalance.ts | 4 ++-- 3 files changed, 7 insertions(+), 12 deletions(-) create mode 100644 packages/ui/src/utils/isTypeAccount.ts diff --git a/packages/ui/src/components/CallInfo.tsx b/packages/ui/src/components/CallInfo.tsx index 8d139172..92cc7eef 100644 --- a/packages/ui/src/components/CallInfo.tsx +++ b/packages/ui/src/components/CallInfo.tsx @@ -13,6 +13,7 @@ import { usePjsLinks } from '../hooks/usePjsLinks' import { Alert } from '@mui/material' import { ApiPromise } from '@polkadot/api' import { isTypeBalance } from '../utils/isTypeBalance' +import { isTypeAccount } from '../utils/isTypeAccount' interface Props { aggregatedData: Omit @@ -100,9 +101,6 @@ const createUlTree = ({ name, args, decimals, unit, api, typeName }: CreateTreeP if (!args) return if (!name) return - const isBalancesTransferAlike = ['balances.transfer', 'balances.transferKeepAlive'].includes(name) - const isProxyCreationDeletion = ['proxy.addProxy', 'proxy.removeProxy'].includes(name) - return (