use transaction state transition instead of other notifications

This commit is contained in:
Sebastian 2023-06-06 14:57:33 -03:00
parent d8d214942c
commit 734de5d359
No known key found for this signature in database
GPG Key ID: 173909D1A5F66069
6 changed files with 7 additions and 7 deletions

View File

@ -49,7 +49,7 @@ export function PendingTransactions({ goToTransaction }: Props): VNode {
useEffect(() => {
return api.listener.onUpdateNotification(
[NotificationType.WithdrawGroupFinished],
[NotificationType.TransactionStateTransition],
state?.retry,
);
});

View File

@ -60,7 +60,7 @@ export function useComponentState({
useEffect(() =>
api.listener.onUpdateNotification(
[NotificationType.RefreshMelted],
[NotificationType.TransactionStateTransition],
info?.retry,
),
);

View File

@ -260,7 +260,7 @@ describe("Refund CTA states", () => {
// expect(state.products).undefined;
// expect(state.amount).deep.eq(Amounts.parseOrThrow("EUR:2"));
// // expect(state.progress).closeTo(1 / 3, 0.01)
// handler.notifyEventFromWallet(NotificationType.RefreshMelted);
// handler.notifyEventFromWallet(NotificationType.TransactionStateTransition);
// },
// (state) => {
// if (state.status !== "in-progress") expect.fail();
@ -269,7 +269,7 @@ describe("Refund CTA states", () => {
// expect(state.products).undefined;
// expect(state.amount).deep.eq(Amounts.parseOrThrow("EUR:2"));
// // expect(state.progress).closeTo(2 / 3, 0.01)
// handler.notifyEventFromWallet(NotificationType.RefreshMelted);
// handler.notifyEventFromWallet(NotificationType.TransactionStateTransition);
// },
// (state) => {
// if (state.status !== "ready") expect.fail();

View File

@ -87,7 +87,7 @@ function useComponentState({
useEffect(() =>
api.listener.onUpdateNotification(
[NotificationType.WithdrawGroupFinished],
[NotificationType.TransactionStateTransition],
state?.retry,
),
);

View File

@ -62,7 +62,7 @@ export function HistoryPage({
useEffect(() => {
return api.listener.onUpdateNotification(
[NotificationType.WithdrawGroupFinished],
[NotificationType.TransactionStateTransition],
state?.retry,
);
});

View File

@ -94,7 +94,7 @@ export function TransactionPage({ tid, goToWalletHistory }: Props): VNode {
useEffect(() =>
api.listener.onUpdateNotification(
[NotificationType.WithdrawGroupFinished, NotificationType.KycRequested],
[NotificationType.TransactionStateTransition],
state?.retry,
),
);