This commit is contained in:
Sebastian 2023-02-17 16:29:09 -03:00
parent 9697e953f5
commit a45759e2ad
No known key found for this signature in database
GPG Key ID: BE4FF68352439FC1
5 changed files with 27 additions and 9 deletions

View File

@ -14,9 +14,7 @@
GNU Taler; see the file COPYING. If not, see <http://www.gnu.org/licenses/> GNU Taler; see the file COPYING. If not, see <http://www.gnu.org/licenses/>
*/ */
import { import { Amounts, TalerProtocolTimestamp } from "@gnu-taler/taler-util";
Amounts, TalerProtocolTimestamp
} from "@gnu-taler/taler-util";
import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; import { WalletApiOperation } from "@gnu-taler/taler-wallet-core";
import { isFuture, parse } from "date-fns"; import { isFuture, parse } from "date-fns";
import { useState } from "preact/hooks"; import { useState } from "preact/hooks";

View File

@ -16,7 +16,8 @@
import { import {
AbsoluteTime, AbsoluteTime,
Amounts, TalerProtocolTimestamp Amounts,
TalerProtocolTimestamp,
} from "@gnu-taler/taler-util"; } from "@gnu-taler/taler-util";
import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; import { WalletApiOperation } from "@gnu-taler/taler-wallet-core";
import { alertFromError, useAlertContext } from "../../context/alert.js"; import { alertFromError, useAlertContext } from "../../context/alert.js";

View File

@ -16,7 +16,12 @@
import { ComponentChildren, h, VNode, JSX } from "preact"; import { ComponentChildren, h, VNode, JSX } from "preact";
import { css } from "@linaria/core"; import { css } from "@linaria/core";
// eslint-disable-next-line import/extensions // eslint-disable-next-line import/extensions
import { theme, Colors, rippleEnabled, rippleEnabledOutlined } from "./style.js"; import {
theme,
Colors,
rippleEnabled,
rippleEnabledOutlined,
} from "./style.js";
// eslint-disable-next-line import/extensions // eslint-disable-next-line import/extensions
import { alpha } from "./colors/manipulation.js"; import { alpha } from "./colors/manipulation.js";
import { useState } from "preact/hooks"; import { useState } from "preact/hooks";

View File

@ -42,6 +42,7 @@ import { Amount } from "../components/Amount.js";
import { BankDetailsByPaytoType } from "../components/BankDetailsByPaytoType.js"; import { BankDetailsByPaytoType } from "../components/BankDetailsByPaytoType.js";
import { CopyButton } from "../components/CopyButton.js"; import { CopyButton } from "../components/CopyButton.js";
import { AlertView, ErrorAlertView } from "../components/CurrentAlerts.js"; import { AlertView, ErrorAlertView } from "../components/CurrentAlerts.js";
import { JustInDevMode } from "../components/JustInDevMode.js";
import { Loading } from "../components/Loading.js"; import { Loading } from "../components/Loading.js";
import { Kind, Part, PartCollapsible, PartPayto } from "../components/Part.js"; import { Kind, Part, PartCollapsible, PartPayto } from "../components/Part.js";
import { QR } from "../components/QR.js"; import { QR } from "../components/QR.js";
@ -362,7 +363,20 @@ function TransactionTemplate({
> >
<i18n.Translate>Cancel</i18n.Translate> <i18n.Translate>Cancel</i18n.Translate>
</Button> </Button>
) : undefined ) : (
//WORKAROUND
//Able to delete tx in dev mode
//FIXME: remove this when DD37 is implemented
<JustInDevMode>
<Button
variant="contained"
color="error"
onClick={doCheckBeforeForget as SafeHandler<void>}
>
<i18n.Translate>Forget</i18n.Translate>
</Button>
</JustInDevMode>
)
) : ( ) : (
<Button <Button
variant="contained" variant="contained"

View File

@ -29,18 +29,18 @@ import {
NotificationType, NotificationType,
TalerErrorCode, TalerErrorCode,
TalerErrorDetail, TalerErrorDetail,
WalletDiagnostics WalletDiagnostics,
} from "@gnu-taler/taler-util"; } from "@gnu-taler/taler-util";
import { import {
WalletCoreApiClient, WalletCoreApiClient,
WalletCoreOpKeys, WalletCoreOpKeys,
WalletCoreRequestType, WalletCoreRequestType,
WalletCoreResponseType WalletCoreResponseType,
} from "@gnu-taler/taler-wallet-core"; } from "@gnu-taler/taler-wallet-core";
import { import {
MessageFromBackend, MessageFromBackend,
MessageFromFrontendBackground, MessageFromFrontendBackground,
MessageFromFrontendWallet MessageFromFrontendWallet,
} from "./platform/api.js"; } from "./platform/api.js";
import { platform } from "./platform/foreground.js"; import { platform } from "./platform/foreground.js";