diff --git a/__tests__/components/__snapshots__/Settings.test.js.snap b/__tests__/components/__snapshots__/Settings.test.js.snap index 02e5114cf..a17aa049b 100644 --- a/__tests__/components/__snapshots__/Settings.test.js.snap +++ b/__tests__/components/__snapshots__/Settings.test.js.snap @@ -923,7 +923,7 @@ exports[`Settings renders without crashing 1`] = ` Manage your neon wallet - v - 2.12.3 + 2.12.4
React$Node | null, + asset: { + symbol: string, + image?: string, + }, + blocktime: number, + amount: string | number, + to: string, + confirmations: number, + + renderTxDate: (time: number) => React$Node | null, +} + +class N3PendingAbstract extends React.Component { + render = () => { + const { + asset, + amount, + to, + blocktime, + findContact, + confirmations, + renderTxDate, + } = this.props + const contactTo = findContact(to) + const logo = asset.image && ( + {`${asset.symbol} + ) + + return ( + +
+
+
+
+ +
+
+ {!blocktime ? ( +
+ awaiting confirmations... +
+ ) : ( + renderTxDate(blocktime) + )} +
Transfer
+
+ +
+
+
+ {logo} + {asset.symbol} +
+
{amount}
+
+
+

{contactTo}

+
+
+
+ {confirmations || 0}{' '} + {pluralize('Confirmation', confirmations || 0)} +
+
+
+ ) + } +} + +export default injectIntl(N3PendingAbstract) diff --git a/app/components/Blockchain/Transaction/Transaction.jsx b/app/components/Blockchain/Transaction/Transaction.jsx index 94f5fa82d..1361a0bd4 100644 --- a/app/components/Blockchain/Transaction/Transaction.jsx +++ b/app/components/Blockchain/Transaction/Transaction.jsx @@ -22,6 +22,7 @@ import Tooltip from '../../Tooltip' import styles from './Transaction.scss' import N3NEP11ReceiveAbstract from './N3NEP11ReceiveAbstract' import N3NEP11SendAbstract from './N3NEP11SendAbstract' +import N3PendingAbstract from './N3PendingAbstract' type Props = { address: string, @@ -43,6 +44,7 @@ type Props = { }, showAddContactModal: ({ address: string }) => null, tx: Object, + renderN2Tx?: boolean, } export default class Transaction extends React.Component { @@ -56,10 +58,13 @@ export default class Transaction extends React.Component { chain, className, isPending, + renderN2Tx, } = this.props return (
- {chain === 'neo3' ? this.renderAbstractN3() : this.renderAbstract(type)} + {chain === 'neo3' && !renderN2Tx + ? this.renderAbstractN3() + : this.renderAbstract(type)} {!isPending && (