File tree Expand file tree Collapse file tree 3 files changed +25
-1
lines changed
pages/RuntimeTransactionDetailPage Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Original file line number Diff line number Diff line change 1+ Display number of shares in Sapphire undelegate transactions
Original file line number Diff line number Diff line change @@ -157,7 +157,16 @@ export const RuntimeTransactions: FC<TransactionsProps> = ({
157157 } ,
158158 {
159159 align : TableCellAlign . Right ,
160- content : < RoundedBalance value = { transaction . amount } ticker = { transaction . amount_symbol } /> ,
160+ content :
161+ transaction . amount && transaction . amount !== '0' ? (
162+ < RoundedBalance value = { transaction . amount } ticker = { transaction . amount_symbol } />
163+ ) : (
164+ < RoundedBalance
165+ compactLargeNumbers
166+ value = { transaction ?. body ?. shares }
167+ ticker = { t ( 'common.shares' ) }
168+ />
169+ ) ,
161170 key : 'value' ,
162171 } ,
163172 {
Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ import { MultipleTransactionsWarning } from '../../components/Transactions/Multi
3333import { JsonCodeDisplay } from '../..//components/CodeDisplay'
3434import { isRoflTransaction } from '../../utils/transaction'
3535import Box from '@mui/material/Box'
36+ import { RoundedBalance } from 'app/components/RoundedBalance'
3637
3738export const RuntimeTransactionDetailPage : FC = ( ) => {
3839 const { t } = useTranslation ( )
@@ -210,6 +211,19 @@ export const RuntimeTransactionDetailView: FC<{
210211 : t ( 'common.missing' ) }
211212 </ dd >
212213
214+ { transaction ?. body ?. shares && (
215+ < >
216+ < dt > { t ( 'common.shares' ) } </ dt >
217+ < dd >
218+ < RoundedBalance
219+ compactLargeNumbers
220+ value = { transaction ?. body ?. shares }
221+ ticker = { t ( 'common.shares' ) }
222+ />
223+ </ dd >
224+ </ >
225+ ) }
226+
213227 { showFiatValues &&
214228 transaction . amount !== undefined &&
215229 ! ! amountSymbolPriceInfo &&
You can’t perform that action at this time.
0 commit comments