Skip to content

Commit

Permalink
show Max output only if it is defined
Browse files Browse the repository at this point in the history
  • Loading branch information
lendihop committed Oct 26, 2023
1 parent b3c892e commit cd65ba2
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/app/templates/TopUpInput/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -188,9 +188,11 @@ const ErrorsComponent: React.FC<ErrorsComponentProps> = ({
<p className={classNames(isInsufficientTezBalanceError ? 'text-red-700' : 'text-transparent')}>
<T id="insufficientTezBalance" />
</p>
<p className={getSmallErrorText(isMaxAmountError)}>
<CurrencyText className={getBigErrorText(isMaxAmountError)} coin={coin} maxAmount={maxAmount} />
</p>
{maxAmount && (
<p className={getSmallErrorText(isMaxAmountError)}>
<CurrencyText className={getBigErrorText(isMaxAmountError)} coin={coin} maxAmount={maxAmount} />
</p>
)}
</div>
);

Expand Down

0 comments on commit cd65ba2

Please sign in to comment.