diff options
Diffstat (limited to 'packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx')
-rw-r--r-- | packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx | 34 |
1 files changed, 22 insertions, 12 deletions
diff --git a/packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx b/packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx index 2960c3168..71bdb20b8 100644 --- a/packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx +++ b/packages/taler-wallet-webextension/src/cta/InvoicePay/views.tsx @@ -20,19 +20,10 @@ import { ErrorTalerOperation } from "../../components/ErrorTalerOperation.js"; import { LoadingError } from "../../components/LoadingError.js"; import { LogoHeader } from "../../components/LogoHeader.js"; import { Part } from "../../components/Part.js"; -import { QR } from "../../components/QR.js"; -import { - Link, - SubTitle, - SvgIcon, - WalletAction, -} from "../../components/styled/index.js"; +import { Link, SubTitle, WalletAction } from "../../components/styled/index.js"; +import { Time } from "../../components/Time.js"; import { useTranslationContext } from "../../context/translation.js"; import { Button } from "../../mui/Button.js"; -import { Grid } from "../../mui/Grid.js"; -import { TextField } from "../../mui/TextField.js"; -import editIcon from "../../svg/edit_24px.svg"; -import { ExchangeDetails, InvoiceDetails } from "../../wallet/Transaction.js"; import { State } from "./index.js"; export function LoadingUriView({ error }: State.LoadingUriError): VNode { @@ -48,7 +39,10 @@ export function LoadingUriView({ error }: State.LoadingUriError): VNode { export function ReadyView({ operationError, + cancel, accept, + expiration, + summary, amount, }: State.Ready): VNode { const { i18n } = useTranslationContext(); @@ -71,15 +65,31 @@ export function ReadyView({ )} <section style={{ textAlign: "left" }}> <Part + title={<i18n.Translate>Subject</i18n.Translate>} + text={<div>{summary}</div>} + /> + <Part title={<i18n.Translate>Amount</i18n.Translate>} text={<Amount value={amount} />} /> + <Part + title={<i18n.Translate>Valid until</i18n.Translate>} + text={<Time timestamp={expiration} format="dd MMMM yyyy, HH:mm" />} + kind="neutral" + /> </section> <section> <Button variant="contained" color="success" onClick={accept.onClick}> - <i18n.Translate>Pay</i18n.Translate> + <i18n.Translate> + Pay {<Amount value={amount} />} + </i18n.Translate> </Button> </section> + <section> + <Link upperCased onClick={cancel.onClick}> + <i18n.Translate>Cancel</i18n.Translate> + </Link> + </section> </WalletAction> ); } |