diff options
Diffstat (limited to 'packages/taler-wallet-webextension/src/components/BalanceTable.tsx')
-rw-r--r-- | packages/taler-wallet-webextension/src/components/BalanceTable.tsx | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/packages/taler-wallet-webextension/src/components/BalanceTable.tsx b/packages/taler-wallet-webextension/src/components/BalanceTable.tsx index e1c19cc23..cf396e129 100644 --- a/packages/taler-wallet-webextension/src/components/BalanceTable.tsx +++ b/packages/taler-wallet-webextension/src/components/BalanceTable.tsx @@ -16,9 +16,18 @@ import { amountFractionalBase, Amounts, Balance } from "@gnu-taler/taler-util"; import { h, VNode } from "preact"; -import { TableWithRoundRows as TableWithRoundedRows } from "./styled/index"; +import { + ButtonPrimary, + TableWithRoundRows as TableWithRoundedRows, +} from "./styled/index"; -export function BalanceTable({ balances }: { balances: Balance[] }): VNode { +export function BalanceTable({ + balances, + goToWalletDeposit, +}: { + balances: Balance[]; + goToWalletDeposit: (currency: string) => void; +}): VNode { const currencyFormatter = new Intl.NumberFormat("en-US"); return ( <TableWithRoundedRows> @@ -40,6 +49,11 @@ export function BalanceTable({ balances }: { balances: Balance[] }): VNode { > {v} </td> + <td> + <ButtonPrimary onClick={() => goToWalletDeposit(av.currency)}> + Deposit + </ButtonPrimary> + </td> </tr> ); })} |