-fix botched Balance->WalletBalance rename
This commit is contained in:
parent
a99156ed22
commit
6b63ecc49e
@ -154,7 +154,7 @@ export interface ChallengeContactData {
|
|||||||
phone?: string;
|
phone?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface Balance {
|
export interface AccountBalance {
|
||||||
amount: AmountString;
|
amount: AmountString;
|
||||||
credit_debit_indicator: "credit" | "debit";
|
credit_debit_indicator: "credit" | "debit";
|
||||||
}
|
}
|
||||||
@ -204,7 +204,7 @@ export interface AccountData {
|
|||||||
name: string;
|
name: string;
|
||||||
|
|
||||||
// Available balance on the account.
|
// Available balance on the account.
|
||||||
balance: Balance;
|
balance: AccountBalance;
|
||||||
|
|
||||||
// payto://-URI of the account.
|
// payto://-URI of the account.
|
||||||
payto_uri: string;
|
payto_uri: string;
|
||||||
|
@ -14,15 +14,15 @@
|
|||||||
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 { Amounts, Balance } from "@gnu-taler/taler-util";
|
import { Amounts, WalletBalance } from "@gnu-taler/taler-util";
|
||||||
import { h, VNode } from "preact";
|
import { VNode, h } from "preact";
|
||||||
import { TableWithRoundRows as TableWithRoundedRows } from "./styled/index.js";
|
import { TableWithRoundRows as TableWithRoundedRows } from "./styled/index.js";
|
||||||
|
|
||||||
export function BalanceTable({
|
export function BalanceTable({
|
||||||
balances,
|
balances,
|
||||||
goToWalletHistory,
|
goToWalletHistory,
|
||||||
}: {
|
}: {
|
||||||
balances: Balance[];
|
balances: WalletBalance[];
|
||||||
goToWalletHistory: (currency: string) => void;
|
goToWalletHistory: (currency: string) => void;
|
||||||
}): VNode {
|
}): VNode {
|
||||||
return (
|
return (
|
||||||
|
@ -14,25 +14,29 @@
|
|||||||
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 { Amounts, Balance, NotificationType } from "@gnu-taler/taler-util";
|
import {
|
||||||
|
Amounts,
|
||||||
|
NotificationType,
|
||||||
|
WalletBalance,
|
||||||
|
} from "@gnu-taler/taler-util";
|
||||||
import { WalletApiOperation } from "@gnu-taler/taler-wallet-core";
|
import { WalletApiOperation } from "@gnu-taler/taler-wallet-core";
|
||||||
import { Fragment, h, VNode } from "preact";
|
import { useTranslationContext } from "@gnu-taler/web-util/browser";
|
||||||
|
import { Fragment, VNode, h } from "preact";
|
||||||
import { useEffect, useState } from "preact/hooks";
|
import { useEffect, useState } from "preact/hooks";
|
||||||
import { BalanceTable } from "../components/BalanceTable.js";
|
import { BalanceTable } from "../components/BalanceTable.js";
|
||||||
import { ErrorAlertView } from "../components/CurrentAlerts.js";
|
import { ErrorAlertView } from "../components/CurrentAlerts.js";
|
||||||
import { Loading } from "../components/Loading.js";
|
import { Loading } from "../components/Loading.js";
|
||||||
import { MultiActionButton } from "../components/MultiActionButton.js";
|
import { MultiActionButton } from "../components/MultiActionButton.js";
|
||||||
import {
|
import {
|
||||||
alertFromError,
|
|
||||||
ErrorAlert,
|
ErrorAlert,
|
||||||
|
alertFromError,
|
||||||
useAlertContext,
|
useAlertContext,
|
||||||
} from "../context/alert.js";
|
} from "../context/alert.js";
|
||||||
import { useBackendContext } from "../context/backend.js";
|
import { useBackendContext } from "../context/backend.js";
|
||||||
import { useTranslationContext } from "@gnu-taler/web-util/browser";
|
|
||||||
import { useAsyncAsHook } from "../hooks/useAsyncAsHook.js";
|
import { useAsyncAsHook } from "../hooks/useAsyncAsHook.js";
|
||||||
import { Button } from "../mui/Button.js";
|
import { Button } from "../mui/Button.js";
|
||||||
import { ButtonHandler } from "../mui/handlers.js";
|
import { ButtonHandler } from "../mui/handlers.js";
|
||||||
import { compose, StateViewMap } from "../utils/index.js";
|
import { StateViewMap, compose } from "../utils/index.js";
|
||||||
import { AddNewActionView } from "../wallet/AddNewActionView.js";
|
import { AddNewActionView } from "../wallet/AddNewActionView.js";
|
||||||
import { NoBalanceHelp } from "./NoBalanceHelp.js";
|
import { NoBalanceHelp } from "./NoBalanceHelp.js";
|
||||||
|
|
||||||
@ -64,7 +68,7 @@ export namespace State {
|
|||||||
export interface Balances {
|
export interface Balances {
|
||||||
status: "balance";
|
status: "balance";
|
||||||
error: undefined;
|
error: undefined;
|
||||||
balances: Balance[];
|
balances: WalletBalance[];
|
||||||
addAction: ButtonHandler;
|
addAction: ButtonHandler;
|
||||||
goToWalletDeposit: (currency: string) => Promise<void>;
|
goToWalletDeposit: (currency: string) => Promise<void>;
|
||||||
goToWalletHistory: (currency: string) => Promise<void>;
|
goToWalletHistory: (currency: string) => Promise<void>;
|
||||||
|
@ -17,26 +17,26 @@
|
|||||||
import {
|
import {
|
||||||
AbsoluteTime,
|
AbsoluteTime,
|
||||||
Amounts,
|
Amounts,
|
||||||
Balance,
|
|
||||||
NotificationType,
|
NotificationType,
|
||||||
Transaction,
|
Transaction,
|
||||||
|
WalletBalance,
|
||||||
} 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 { Fragment, h, VNode } from "preact";
|
import { useTranslationContext } from "@gnu-taler/web-util/browser";
|
||||||
|
import { Fragment, VNode, h } from "preact";
|
||||||
import { useEffect, useState } from "preact/hooks";
|
import { useEffect, useState } from "preact/hooks";
|
||||||
import { ErrorAlertView } from "../components/CurrentAlerts.js";
|
import { ErrorAlertView } from "../components/CurrentAlerts.js";
|
||||||
|
import { HistoryItem } from "../components/HistoryItem.js";
|
||||||
import { Loading } from "../components/Loading.js";
|
import { Loading } from "../components/Loading.js";
|
||||||
|
import { Time } from "../components/Time.js";
|
||||||
import {
|
import {
|
||||||
CenteredBoldText,
|
CenteredBoldText,
|
||||||
CenteredText,
|
CenteredText,
|
||||||
DateSeparator,
|
DateSeparator,
|
||||||
NiceSelect,
|
NiceSelect,
|
||||||
} from "../components/styled/index.js";
|
} from "../components/styled/index.js";
|
||||||
import { Time } from "../components/Time.js";
|
|
||||||
import { HistoryItem } from "../components/HistoryItem.js";
|
|
||||||
import { alertFromError, useAlertContext } from "../context/alert.js";
|
import { alertFromError, useAlertContext } from "../context/alert.js";
|
||||||
import { useBackendContext } from "../context/backend.js";
|
import { useBackendContext } from "../context/backend.js";
|
||||||
import { useTranslationContext } from "@gnu-taler/web-util/browser";
|
|
||||||
import { useAsyncAsHook } from "../hooks/useAsyncAsHook.js";
|
import { useAsyncAsHook } from "../hooks/useAsyncAsHook.js";
|
||||||
import { Button } from "../mui/Button.js";
|
import { Button } from "../mui/Button.js";
|
||||||
import { NoBalanceHelp } from "../popup/NoBalanceHelp.js";
|
import { NoBalanceHelp } from "../popup/NoBalanceHelp.js";
|
||||||
@ -109,7 +109,7 @@ export function HistoryView({
|
|||||||
goToWalletManualWithdraw: (currency?: string) => Promise<void>;
|
goToWalletManualWithdraw: (currency?: string) => Promise<void>;
|
||||||
defaultCurrency?: string;
|
defaultCurrency?: string;
|
||||||
transactions: Transaction[];
|
transactions: Transaction[];
|
||||||
balances: Balance[];
|
balances: WalletBalance[];
|
||||||
}): VNode {
|
}): VNode {
|
||||||
const { i18n } = useTranslationContext();
|
const { i18n } = useTranslationContext();
|
||||||
const { pushAlertOnError } = useAlertContext();
|
const { pushAlertOnError } = useAlertContext();
|
||||||
|
Loading…
Reference in New Issue
Block a user